Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
ruanhaishen
redis
Commits
eb3c5a70
Commit
eb3c5a70
authored
Dec 05, 2018
by
antirez
Browse files
RESP3: hiredis: fix read.c assert for new types.
parent
d5c54f0b
Changes
2
Hide whitespace changes
Inline
Side-by-side
deps/hiredis/hiredis.c
View file @
eb3c5a70
...
...
@@ -123,7 +123,9 @@ static void *createStringObject(const redisReadTask *task, char *str, size_t len
if
(
task
->
parent
)
{
parent
=
task
->
parent
->
obj
;
assert
(
parent
->
type
==
REDIS_REPLY_ARRAY
);
assert
(
parent
->
type
==
REDIS_REPLY_ARRAY
||
parent
->
type
==
REDIS_REPLY_MAP
||
parent
->
type
==
REDIS_REPLY_SET
);
parent
->
element
[
task
->
idx
]
=
r
;
}
return
r
;
...
...
deps/hiredis/read.c
View file @
eb3c5a70
...
...
@@ -243,7 +243,9 @@ static void moveToNextTask(redisReader *r) {
cur
=
&
(
r
->
rstack
[
r
->
ridx
]);
prv
=
&
(
r
->
rstack
[
r
->
ridx
-
1
]);
assert
(
prv
->
type
==
REDIS_REPLY_ARRAY
);
assert
(
prv
->
type
==
REDIS_REPLY_ARRAY
||
prv
->
type
==
REDIS_REPLY_MAP
||
prv
->
type
==
REDIS_REPLY_SET
);
if
(
cur
->
idx
==
prv
->
elements
-
1
)
{
r
->
ridx
--
;
}
else
{
...
...
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