summaryrefslogtreecommitdiff
path: root/src/t_list.c
diff options
context:
space:
mode:
authorantirez <antirez@gmail.com>2013-12-10 18:18:24 +0100
committerantirez <antirez@gmail.com>2013-12-10 18:46:24 +0100
commit2eb781b35bfa9bde5ab88b192cd3e666e7872625 (patch)
treef8eb43b3a8376b178c278ca0ad967f4f3eba0bf4 /src/t_list.c
parent2c4ab8a534f9c1452ea07e51fa1215d8b617b27b (diff)
downloadredis-2eb781b35bfa9bde5ab88b192cd3e666e7872625.tar.gz
dict.c: added optional callback to dictEmpty().
Redis hash table implementation has many non-blocking features like incremental rehashing, however while deleting a large hash table there was no way to have a callback called to do some incremental work. This commit adds this support, as an optiona callback argument to dictEmpty() that is currently called at a fixed interval (one time every 65k deletions).
Diffstat (limited to 'src/t_list.c')
-rw-r--r--src/t_list.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/t_list.c b/src/t_list.c
index 216e071ba..70f5cf164 100644
--- a/src/t_list.c
+++ b/src/t_list.c
@@ -835,7 +835,7 @@ void unblockClientWaitingData(redisClient *c) {
dictReleaseIterator(di);
/* Cleanup the client structure */
- dictEmpty(c->bpop.keys);
+ dictEmpty(c->bpop.keys,NULL);
if (c->bpop.target) {
decrRefCount(c->bpop.target);
c->bpop.target = NULL;