networking: current_client should not be NULL when trim qb_pos

This commit is contained in:
zhaozhao.zz 2018-12-07 19:14:33 +08:00
parent 430a987f4e
commit 28c4281495

View File

@ -1470,7 +1470,7 @@ void processInputBuffer(client *c) {
}
/* Trim to pos */
if (c->qb_pos) {
if (server.current_client != NULL && c->qb_pos) {
sdsrange(c->querybuf,c->qb_pos,-1);
c->qb_pos = 0;
}