Don't have dangling expires
Former-commit-id: 83c8977033d79b6ec69e677dff19f68df53535be
This commit is contained in:
parent
cec7f98f34
commit
589e95e0c8
@ -152,6 +152,13 @@ int dbAsyncDelete(redisDb *db, robj *key) {
|
||||
if (de) {
|
||||
robj *val = (robj*)dictGetVal(de);
|
||||
|
||||
if (val->FExpires())
|
||||
{
|
||||
/* Deleting an entry from the expires dict will not free the sds of
|
||||
* the key, because it is shared with the main dictionary. */
|
||||
removeExpireCore(db,key,de);
|
||||
}
|
||||
|
||||
/* Tells the module that the key has been unlinked from the database. */
|
||||
moduleNotifyKeyUnlink(key,val);
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user