diff --git a/src/networking.c b/src/networking.c index 6d571aad1..66e91c521 100644 --- a/src/networking.c +++ b/src/networking.c @@ -2769,6 +2769,11 @@ void helloCommand(client *c) { return; } + if (!ver && next_arg < c->argc) { + addReplyError(c,"Authentication needs to provide an protocol version"); + return; + } + for (int j = next_arg; j < c->argc; j++) { int moreargs = (c->argc-1) - j; const char *opt = c->argv[j]->ptr;