Assert that setDeferredAggregateLen isn't called with negative value
In case the redis is about to return broken reply we want to crash with assert so that we are notified about the bug. see #7687. (cherry picked from commit 7e6c9ef8819a071679f8dd18035dbbe2455c7b12)
This commit is contained in:
parent
34124fff88
commit
d727f52723
@ -492,6 +492,7 @@ void *addReplyDeferredLen(client *c) {
|
||||
|
||||
/* Populate the length object and try gluing it to the next chunk. */
|
||||
void setDeferredAggregateLen(client *c, void *node, long length, char prefix) {
|
||||
serverAssert(length >= 0);
|
||||
listNode *ln = (listNode*)node;
|
||||
clientReplyBlock *next;
|
||||
char lenstr[128];
|
||||
|
Loading…
x
Reference in New Issue
Block a user