From 99b2c70137fef05a5a18f439b9010ddba455f5cb Mon Sep 17 00:00:00 2001 From: David Härdeman Date: Sat, 27 Jun 2020 15:18:45 +0200 Subject: Create a shared mc protocol implementation and use it in the proxy and cmd line tool --- shared/mc-protocol.h | 13 +++++++++++++ 1 file changed, 13 insertions(+) create mode 100644 shared/mc-protocol.h (limited to 'shared/mc-protocol.h') diff --git a/shared/mc-protocol.h b/shared/mc-protocol.h new file mode 100644 index 0000000..8ecc02a --- /dev/null +++ b/shared/mc-protocol.h @@ -0,0 +1,13 @@ +#ifndef foomcprotocolhfoo +#define foomcprotocolhfoo + +int mc_is_handshake_complete(const char *buf, size_t len); + +bool mc_protocol_parse_status_reply(const char *buf, size_t len, + unsigned *online, unsigned *max); + +bool mc_protocol_create_status_request(char *buf, size_t len, size_t *rlen, + struct saddr *saddr); + +#endif + -- cgit v1.2.3