From d84fa525b59606af7217cd3675ac2af7d486cae4 Mon Sep 17 00:00:00 2001 From: John Sully Date: Fri, 8 Mar 2024 20:21:30 +0000 Subject: [PATCH] Fix crash in FLASH eviction --- src/db.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/db.cpp b/src/db.cpp index bf5b40d68..f32e8084c 100644 --- a/src/db.cpp +++ b/src/db.cpp @@ -3125,10 +3125,10 @@ bool redisDbPersistentData::removeCachedValue(const char *key, dictEntry **ppde) // since we write ASAP the database already has a valid copy so safe to delete if (ppde != nullptr) { + *ppde = dictUnlink(m_pdict, key); robj *o = (robj*)dictGetVal(*ppde); if (o->FExpires()) --m_numexpires; - *ppde = dictUnlink(m_pdict, key); } else { dictEntry *deT = dictFind(m_pdict, key); robj *o = (robj*)dictGetVal(deT);