Co-authored-by: Oran Agra <oran@redislabs.com>
This commit is contained in:
xhe 2020-12-24 17:03:45 +08:00 committed by GitHub
parent c07d3bd8dd
commit 723b4a15a3
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -2763,7 +2763,7 @@ void helloCommand(client *c) {
long long ver = 0; long long ver = 0;
int next_arg = 1; int next_arg = 1;
if (c->argc >= 2 && getLongLongFromObject(c->argv[1],&ver) == C_OK && if (c->argc >= 2 && getLongLongFromObject(c->argv[next_arg++],&ver) == C_OK &&
(ver < 2 || ver > 3)) { (ver < 2 || ver > 3)) {
addReplyError(c,"-NOPROTO unsupported protocol version"); addReplyError(c,"-NOPROTO unsupported protocol version");
return; return;