mirror of
https://codeberg.org/redict/redict.git
synced 2025-01-23 00:28:26 -05:00
parent
ff57b8d550
commit
4e5e0d3719
@ -1466,6 +1466,8 @@ void readQueryFromClient(aeEventLoop *el, int fd, void *privdata, int mask) {
|
|||||||
{
|
{
|
||||||
ssize_t remaining = (size_t)(c->bulklen+2)-sdslen(c->querybuf);
|
ssize_t remaining = (size_t)(c->bulklen+2)-sdslen(c->querybuf);
|
||||||
|
|
||||||
|
/* Note that the 'remaining' variable may be zero in some edge case,
|
||||||
|
* for example once we resume a blocked client after CLIENT PAUSE. */
|
||||||
if (remaining > 0 && remaining < readlen) readlen = remaining;
|
if (remaining > 0 && remaining < readlen) readlen = remaining;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user