Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

fixed memory leak introduced with the previous commit. Many thanks to…

… Pieter Noordhuis for spotting it in no time
  • Loading branch information...
commit fb90934c476ee0ece9b1dc0d9e05c766c96c0b3f 1 parent 207ca3c
@antirez authored
Showing with 4 additions and 1 deletion.
  1. +4 −1 src/networking.c
View
5 src/networking.c
@@ -135,7 +135,10 @@ void _addReplyObjectToList(redisClient *c, robj *o) {
void _addReplySdsToList(redisClient *c, sds s) {
robj *tail;
- if (c->flags & REDIS_CLOSE_AFTER_REPLY) return;
+ if (c->flags & REDIS_CLOSE_AFTER_REPLY) {
+ sdsfree(s);
+ return;
+ }
if (listLength(c->reply) == 0) {
listAddNodeTail(c->reply,createObject(REDIS_STRING,s));
Please sign in to comment.
Something went wrong with that request. Please try again.