summaryrefslogtreecommitdiff
path: root/src/debug.c
diff options
context:
space:
mode:
authorantirez <antirez@gmail.com>2014-05-09 15:02:29 +0200
committerantirez <antirez@gmail.com>2014-05-09 15:02:29 +0200
commit72ff03346fcf3d5a839b85bd1ebd7850c2e5d9aa (patch)
treedb249fb1f4565b21b355686ce398a86d11529a36 /src/debug.c
parent8a170c817dd17be2823339620de1cf2ea8aa1468 (diff)
downloadredis-72ff03346fcf3d5a839b85bd1ebd7850c2e5d9aa.tar.gz
DEBUG POPULATE: call dictExpand() to avoid useless rehashing.
Diffstat (limited to 'src/debug.c')
-rw-r--r--src/debug.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/debug.c b/src/debug.c
index 1869f7553..3fb491cb7 100644
--- a/src/debug.c
+++ b/src/debug.c
@@ -326,6 +326,7 @@ void debugCommand(redisClient *c) {
if (getLongFromObjectOrReply(c, c->argv[2], &keys, NULL) != REDIS_OK)
return;
+ dictExpand(c->db->dict,keys);
for (j = 0; j < keys; j++) {
snprintf(buf,sizeof(buf),"key:%lu",j);
key = createStringObject(buf,strlen(buf));