From 42dc0e98aa43f755fc8a6c087d35ce00b5007c0a Mon Sep 17 00:00:00 2001 From: Pierre Jambet Date: Wed, 2 Sep 2020 16:27:48 -0400 Subject: [PATCH] Fix error message for the DEBUG ZIPLIST command (#7745) DEBUG ZIPLIST currently returns the following error string if the key is not a ziplist: "ERR Not an sds encoded string.". This looks like an accidental copy/paste error from the error returned in the else if branch above where this string is returned if the key is not an sds string. The command was added in f898429fe149f476d61270ed4299dd1f8f75ae50 and looking at the commit, nothing indicates that it is not an accidental typo. The error string now returns a correct error: "Not a ziplist encoded object", which accurately describes the error. --- src/debug.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/debug.c b/src/debug.c index b05dc344e..373938e6e 100644 --- a/src/debug.c +++ b/src/debug.c @@ -588,7 +588,7 @@ NULL == NULL) return; if (o->encoding != OBJ_ENCODING_ZIPLIST) { - addReplyError(c,"Not an sds encoded string."); + addReplyError(c,"Not a ziplist encoded object."); } else { ziplistRepr(o->ptr); addReplyStatus(c,"Ziplist structure printed on stdout");