Streams: fix memory leak in freeStream().

This commit is contained in:
antirez 2017-09-12 10:54:20 +02:00
parent 3a0b78bc52
commit 94af55c5ea

View File

@ -54,6 +54,7 @@ stream *streamNew(void) {
/* Free a stream, including the listpacks stored inside the radix tree. */ /* Free a stream, including the listpacks stored inside the radix tree. */
void freeStream(stream *s) { void freeStream(stream *s) {
raxFreeWithCallback(s->rax,(void(*)(void*))lpFree); raxFreeWithCallback(s->rax,(void(*)(void*))lpFree);
zfree(s);
} }
/* Generate the next stream item ID given the previous one. If the current /* Generate the next stream item ID given the previous one. If the current