Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
ruanhaishen
redis
Commits
998001fb
Commit
998001fb
authored
Oct 25, 2018
by
antirez
Browse files
Merge branch 'unstable' of github.com:/antirez/redis into unstable
parents
6e11ef30
12d5be1b
Changes
2
Show whitespace changes
Inline
Side-by-side
src/db.c
View file @
998001fb
...
...
@@ -104,7 +104,10 @@ robj *lookupKeyReadWithFlags(redisDb *db, robj *key, int flags) {
/* Key expired. If we are in the context of a master, expireIfNeeded()
* returns 0 only when the key does not exist at all, so it's safe
* to return NULL ASAP. */
if
(
server
.
masterhost
==
NULL
)
return
NULL
;
if
(
server
.
masterhost
==
NULL
)
{
server
.
stat_keyspace_misses
++
;
return
NULL
;
}
/* However if we are in the context of a slave, expireIfNeeded() will
* not really try to expire the key, it only returns information
...
...
@@ -123,6 +126,7 @@ robj *lookupKeyReadWithFlags(redisDb *db, robj *key, int flags) {
server
.
current_client
->
cmd
&&
server
.
current_client
->
cmd
->
flags
&
CMD_READONLY
)
{
server
.
stat_keyspace_misses
++
;
return
NULL
;
}
}
...
...
src/t_stream.c
View file @
998001fb
...
...
@@ -1898,7 +1898,7 @@ void xackCommand(client *c) {
addReplyLongLong
(
c
,
acknowledged
);
}
/* XPENDING <key> <group> [<start> <stop> <count>
]
[<consumer>]
/* XPENDING <key> <group> [<start> <stop> <count> [<consumer>]
]
*
* If start and stop are omitted, the command just outputs information about
* the amount of pending messages for the key/group pair, together with
...
...
@@ -1927,6 +1927,7 @@ void xpendingCommand(client *c) {
if
(
c
->
argc
>=
6
)
{
if
(
getLongLongFromObjectOrReply
(
c
,
c
->
argv
[
5
],
&
count
,
NULL
)
==
C_ERR
)
return
;
if
(
count
<
0
)
count
=
0
;
if
(
streamParseIDOrReply
(
c
,
c
->
argv
[
3
],
&
startid
,
0
)
==
C_ERR
)
return
;
if
(
streamParseIDOrReply
(
c
,
c
->
argv
[
4
],
&
endid
,
UINT64_MAX
)
==
C_ERR
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment