X-Git-Url: http://git.tuebingen.mpg.de/?p=paraslash.git;a=blobdiff_plain;f=command.c;h=8fdb839a97be1e6c459f5911621fffa88d61410b;hp=70aefae10738cd0eaed813e47fe17602b0c531c7;hb=ef81b9f4f0fa6a26043c68d429c0deeb7c949351;hpb=5440b8c0464829022a0ba5dd5daa931b15712a11 diff --git a/command.c b/command.c index 70aefae1..8fdb839a 100644 --- a/command.c +++ b/command.c @@ -6,6 +6,7 @@ /** \file command.c Client authentication and server commands. */ +#include #include #include #include @@ -367,6 +368,7 @@ int com_stat(struct rc4_context *rc4c, int argc, char * const * argv) parser_friendly = 1; continue; } + return -E_COMMAND_SYNTAX; } if (i != argc) return -E_COMMAND_SYNTAX; @@ -776,7 +778,7 @@ __noreturn void handle_connect(int fd, const char *peername) numbytes = 256; get_random_bytes_or_die((unsigned char *)buf, numbytes); } - PARA_DEBUG_LOG("sending %zu byte challenge + rc4 keys (%u bytes)\n", + PARA_DEBUG_LOG("sending %u byte challenge + rc4 keys (%zu bytes)\n", CHALLENGE_SIZE, numbytes); ret = send_bin_buffer(fd, buf, numbytes); if (ret < 0) @@ -786,7 +788,7 @@ __noreturn void handle_connect(int fd, const char *peername) if (ret < 0) goto net_err; numbytes = ret; - PARA_DEBUG_LOG("received %zu bytes challenge response\n", ret); + PARA_DEBUG_LOG("received %d bytes challenge response\n", ret); ret = -E_BAD_USER; if (!u) goto net_err;