From 96ab9c58ae534d38094327ac4a72cd3c4d4f21bf Mon Sep 17 00:00:00 2001 From: John Sully Date: Mon, 15 Mar 2021 05:46:52 +0000 Subject: [PATCH] We can't swap databases if there are async rehashes Former-commit-id: 4b8967f94667309c5585032db7403bf4c8885145 --- src/dict.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/dict.cpp b/src/dict.cpp index f25eff002..4afcb3bf7 100644 --- a/src/dict.cpp +++ b/src/dict.cpp @@ -195,7 +195,7 @@ int dictMerge(dict *dst, dict *src) } size_t expectedSize = dictSize(src) + dictSize(dst); - if (dictSize(src) > dictSize(dst)) + if (dictSize(src) > dictSize(dst) && src->asyncdata == nullptr && dst->asyncdata == nullptr) { std::swap(*dst, *src); std::swap(dst->iterators, src->iterators);