mirror of
https://codeberg.org/redict/redict.git
synced 2025-01-22 08:08:53 -05:00
redis-benchmark sync with the new protocol
This commit is contained in:
parent
0c9ca0e11c
commit
4c26a79a8d
@ -190,11 +190,11 @@ static void readHandler(aeEventLoop *el, int fd, void *privdata, int mask)
|
|||||||
if (c->replytype == REPLY_BULK) {
|
if (c->replytype == REPLY_BULK) {
|
||||||
*p = '\0';
|
*p = '\0';
|
||||||
*(p-1) = '\0';
|
*(p-1) = '\0';
|
||||||
if (memcmp(c->ibuf,"nil",3) == 0) {
|
c->readlen = atoi(c->ibuf+1)+2;
|
||||||
|
if (c->readlen == -1) {
|
||||||
clientDone(c);
|
clientDone(c);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
c->readlen = atoi(c->ibuf)+2;
|
|
||||||
c->ibuf = sdsrange(c->ibuf,(p-c->ibuf)+1,-1);
|
c->ibuf = sdsrange(c->ibuf,(p-c->ibuf)+1,-1);
|
||||||
} else {
|
} else {
|
||||||
c->ibuf = sdstrim(c->ibuf,"\r\n");
|
c->ibuf = sdstrim(c->ibuf,"\r\n");
|
||||||
|
Loading…
Reference in New Issue
Block a user