In activeDefragStringOb, we have took care defragged so not need to self-incr. (#8952)

incrementing the defragged hits counter twice in activeDefragSdsListAndDict
This commit is contained in:
Binbin 2021-05-18 23:33:01 +08:00 committed by GitHub
parent 25d827d949
commit 09a99fcd5f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -365,7 +365,7 @@ long activeDefragSdsListAndDict(list *l, dict *d, int dict_val_type) {
} else if (dict_val_type == DEFRAG_SDS_DICT_VAL_IS_STROB) {
robj *newele, *ele = dictGetVal(de);
if ((newele = activeDefragStringOb(ele, &defragged)))
de->v.val = newele, defragged++;
de->v.val = newele;
} else if (dict_val_type == DEFRAG_SDS_DICT_VAL_VOID_PTR) {
void *newptr, *ptr = dictGetVal(de);
if ((newptr = activeDefragAlloc(ptr)))