Commit 3bc35f9c authored by antirez's avatar antirez
Browse files

Correctly replicate PFDEBUG GETREG.

Even if it is a debugging command, make sure that when it forces a
change in encoding, the command is propagated.
parent ba0afb45
...@@ -1306,9 +1306,12 @@ void pfdebugCommand(redisClient *c) { ...@@ -1306,9 +1306,12 @@ void pfdebugCommand(redisClient *c) {
if (!strcasecmp(cmd,"getreg")) { if (!strcasecmp(cmd,"getreg")) {
if (c->argc != 3) goto arityerr; if (c->argc != 3) goto arityerr;
if (hllSparseToDense(o) == REDIS_ERR) { if (hdr->encoding == HLL_SPARSE) {
addReplyError(c,"HLL sparse encoding is corrupted"); if (hllSparseToDense(o) == REDIS_ERR) {
return; addReplyError(c,"HLL sparse encoding is corrupted");
return;
}
server.dirty++; /* Force propagation on encoding change. */
} }
hdr = o->ptr; hdr = o->ptr;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment