From ea053d96f7e89e053d4af8d39b04c5428760345f Mon Sep 17 00:00:00 2001 From: David Härdeman Date: Tue, 23 Jun 2020 20:56:22 +0200 Subject: Big renaming, move some more functionality to shared lib --- mcserverctl/mcserverctl.c | 40 ---------------------------------------- mcserverctl/meson.build | 14 -------------- 2 files changed, 54 deletions(-) delete mode 100644 mcserverctl/mcserverctl.c delete mode 100644 mcserverctl/meson.build (limited to 'mcserverctl') diff --git a/mcserverctl/mcserverctl.c b/mcserverctl/mcserverctl.c deleted file mode 100644 index e29dcef..0000000 --- a/mcserverctl/mcserverctl.c +++ /dev/null @@ -1,40 +0,0 @@ -#include -#include -#include -#include - -#include "rcon-protocol.h" - -int -main(int argc, char **argv) -{ - char buf[4096]; - size_t len; - int32_t id, type; - const char *msg, *error; - - fprintf(stderr, "Started\n"); - - if (!rcon_protocol_create_packet(buf, sizeof(buf), &len, - 1, RCON_PACKET_LOGIN, - "test")) { - fprintf(stderr, "Failed to create packet\n"); - exit(EXIT_FAILURE); - } - - if (!rcon_protocol_packet_complete(buf, len)) { - fprintf(stderr, "Packet not complete\n"); - exit(EXIT_FAILURE); - } - - if (!rcon_protocol_read_packet(buf, len, &id, &type, &msg, &error)) { - fprintf(stderr, "Packet parsing failed: %s\n", error); - exit(EXIT_FAILURE); - } - - fprintf(stderr, "Packet - id: %" PRIi32 ", type: %" PRIi32 ", msg: %s\n", - id, type, msg); - - exit(EXIT_SUCCESS); -} - diff --git a/mcserverctl/meson.build b/mcserverctl/meson.build deleted file mode 100644 index 4e960b7..0000000 --- a/mcserverctl/meson.build +++ /dev/null @@ -1,14 +0,0 @@ -mcserverctl_sources = [ - 'mcserverctl.c', -] - -mcserverctl_deps = [ - dep_libshared, -] - -executable( - 'mcserverctl', - mcserverctl_sources, - dependencies: mcserverctl_deps, -) - -- cgit v1.2.3