summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorzhaozhao.zz <276441700@qq.com>2021-02-02 16:51:19 +0800
committerOran Agra <oran@redislabs.com>2021-02-23 01:35:37 +0200
commit56ef0aa7c8416fbba833c85227332dcd5c7be611 (patch)
treeebc2efe4cb8e194730b51b63e8f028eb5795183b
parentdcf409f8e72dcd6bbf2f31d2ecc8f6f797c303c2 (diff)
downloadredis-56ef0aa7c8416fbba833c85227332dcd5c7be611.tar.gz
XINFO should use lookupKeyReadOrReply (#8436)
This bug would have let users observe logically expired keys on replicas and during CLIENT PAUSE WRITE. (cherry picked from commit f2a5fe36789b50dab76851233966aaac44f9048c)
-rw-r--r--src/t_stream.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/t_stream.c b/src/t_stream.c
index 357975079..43b67e882 100644
--- a/src/t_stream.c
+++ b/src/t_stream.c
@@ -2716,7 +2716,7 @@ NULL
key = c->argv[2];
/* Lookup the key now, this is common for all the subcommands but HELP. */
- robj *o = lookupKeyWriteOrReply(c,key,shared.nokeyerr);
+ robj *o = lookupKeyReadOrReply(c,key,shared.nokeyerr);
if (o == NULL || checkType(c,o,OBJ_STREAM)) return;
s = o->ptr;