Commit b9f907fb authored by Jan-Erik Rediger's avatar Jan-Erik Rediger
Browse files

Merge pull request #324 from redis/fix-spontaneous-reply-leak

Fix memory leak in async spontaneous reply handling
parents d8145d79 2fc39eb4
...@@ -454,6 +454,7 @@ void redisProcessCallbacks(redisAsyncContext *ac) { ...@@ -454,6 +454,7 @@ void redisProcessCallbacks(redisAsyncContext *ac) {
if (((redisReply*)reply)->type == REDIS_REPLY_ERROR) { if (((redisReply*)reply)->type == REDIS_REPLY_ERROR) {
c->err = REDIS_ERR_OTHER; c->err = REDIS_ERR_OTHER;
snprintf(c->errstr,sizeof(c->errstr),"%s",((redisReply*)reply)->str); snprintf(c->errstr,sizeof(c->errstr),"%s",((redisReply*)reply)->str);
c->reader->fn->freeObject(reply);
__redisAsyncDisconnect(ac); __redisAsyncDisconnect(ac);
return; return;
} }
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment