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
0a6090bf
Unverified
Commit
0a6090bf
authored
May 02, 2019
by
Salvatore Sanfilippo
Committed by
GitHub
May 02, 2019
Browse files
Merge pull request #6051 from vattezhang/unstable
fix: benchmark auth fails when server have requirepass
parents
843de8b7
4e38ced4
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/redis-benchmark.c
View file @
0a6090bf
...
@@ -254,6 +254,19 @@ static redisConfig *getRedisConfig(const char *ip, int port,
...
@@ -254,6 +254,19 @@ static redisConfig *getRedisConfig(const char *ip, int port,
else
fprintf
(
stderr
,
"%s: %s
\n
"
,
hostsocket
,
err
);
else
fprintf
(
stderr
,
"%s: %s
\n
"
,
hostsocket
,
err
);
goto
fail
;
goto
fail
;
}
}
if
(
config
.
auth
){
void
*
authReply
=
NULL
;
redisAppendCommand
(
c
,
"AUTH %s"
,
config
.
auth
);
if
(
REDIS_OK
!=
redisGetReply
(
c
,
&
authReply
))
goto
fail
;
if
(
reply
)
freeReplyObject
(
reply
);
reply
=
((
redisReply
*
)
authReply
);
if
(
reply
->
type
==
REDIS_REPLY_ERROR
)
{
fprintf
(
stderr
,
"ERROR: %s
\n
"
,
reply
->
str
);
goto
fail
;
}
}
redisAppendCommand
(
c
,
"CONFIG GET %s"
,
"save"
);
redisAppendCommand
(
c
,
"CONFIG GET %s"
,
"save"
);
redisAppendCommand
(
c
,
"CONFIG GET %s"
,
"appendonly"
);
redisAppendCommand
(
c
,
"CONFIG GET %s"
,
"appendonly"
);
int
i
=
0
;
int
i
=
0
;
...
...
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