diff options
author | WuYunlong <xzsyeb@126.com> | 2020-01-07 11:17:52 +0800 |
---|---|---|
committer | WuYunlong <xzsyeb@126.com> | 2020-01-07 11:17:52 +0800 |
commit | d6a13f444003e75e8ccbe97297bf32f0eb58cb23 (patch) | |
tree | 0786c60e1fb1e7bbad639efaf4e78bd2380e7672 | |
parent | 9387f7333e0ccc200dda10032e517e2fb93cc368 (diff) | |
download | redis-d6a13f444003e75e8ccbe97297bf32f0eb58cb23.tar.gz |
Free allocated sds in pfdebugCommand() to avoid memory leak.
-rw-r--r-- | src/hyperloglog.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/hyperloglog.c b/src/hyperloglog.c index a44d15646..facd99743 100644 --- a/src/hyperloglog.c +++ b/src/hyperloglog.c @@ -1535,6 +1535,7 @@ void pfdebugCommand(client *c) { sds decoded = sdsempty(); if (hdr->encoding != HLL_SPARSE) { + sdsfree(decoded); addReplyError(c,"HLL encoding is not sparse"); return; } |