mirror of
https://codeberg.org/redict/redict.git
synced 2025-01-23 08:38:27 -05:00
removed unnecessary refcount increase that caused the HINCRBY memleak
This commit is contained in:
parent
01426b054c
commit
53476b82a1
2
redis.c
2
redis.c
@ -6021,8 +6021,6 @@ static void hincrbyCommand(redisClient *c) {
|
|||||||
value += incr;
|
value += incr;
|
||||||
hval = createObject(REDIS_STRING,sdscatprintf(sdsempty(),"%lld",value));
|
hval = createObject(REDIS_STRING,sdscatprintf(sdsempty(),"%lld",value));
|
||||||
tryObjectEncoding(hval);
|
tryObjectEncoding(hval);
|
||||||
incrRefCount(hval);
|
|
||||||
|
|
||||||
if (dictReplace(o->ptr,c->argv[2],hval)) {
|
if (dictReplace(o->ptr,c->argv[2],hval)) {
|
||||||
incrRefCount(c->argv[2]);
|
incrRefCount(c->argv[2]);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user