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
233d24a7
Commit
233d24a7
authored
Dec 26, 2012
by
Dov Murik
Committed by
antirez
Aug 18, 2014
Browse files
redis-cli: fix prompt after shutdown command
Fix redis-cli prompt to state "not connected" after a SHUTDOWN command is sent.
parent
d786fb6e
Changes
1
Show whitespace changes
Inline
Side-by-side
src/redis-cli.c
View file @
233d24a7
...
@@ -517,8 +517,11 @@ static int cliReadReply(int output_raw_strings) {
...
@@ -517,8 +517,11 @@ static int cliReadReply(int output_raw_strings) {
int
output
=
1
;
int
output
=
1
;
if
(
redisGetReply
(
context
,
&
_reply
)
!=
REDIS_OK
)
{
if
(
redisGetReply
(
context
,
&
_reply
)
!=
REDIS_OK
)
{
if
(
config
.
shutdown
)
if
(
config
.
shutdown
)
{
redisFree
(
context
);
context
=
NULL
;
return
REDIS_OK
;
return
REDIS_OK
;
}
if
(
config
.
interactive
)
{
if
(
config
.
interactive
)
{
/* Filter cases where we should reconnect */
/* Filter cases where we should reconnect */
if
(
context
->
err
==
REDIS_ERR_IO
&&
errno
==
ECONNRESET
)
if
(
context
->
err
==
REDIS_ERR_IO
&&
errno
==
ECONNRESET
)
...
...
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