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
495dd0da
Commit
495dd0da
authored
Aug 02, 2019
by
zhaozhao.zz
Committed by
antirez
Sep 25, 2019
Browse files
networking: flushSlavesOutputBuffers bugfix
parent
c1ccf0f1
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/networking.c
View file @
495dd0da
...
...
@@ -2143,7 +2143,6 @@ void flushSlavesOutputBuffers(void) {
listRewind
(
server
.
slaves
,
&
li
);
while
((
ln
=
listNext
(
&
li
)))
{
client
*
slave
=
listNodeValue
(
ln
);
int
events
;
/* Note that the following will not flush output buffers of slaves
* in STATE_ONLINE but having put_online_on_ack set to true: in this
...
...
@@ -2151,9 +2150,8 @@ void flushSlavesOutputBuffers(void) {
* of put_online_on_ack is to postpone the moment it is installed.
* This is what we want since slaves in this state should not receive
* writes before the first ACK. */
events
=
aeGetFileEvents
(
server
.
el
,
slave
->
fd
);
if
(
events
&
AE_WRITABLE
&&
slave
->
replstate
==
SLAVE_STATE_ONLINE
&&
if
(
slave
->
replstate
==
SLAVE_STATE_ONLINE
&&
!
slave
->
repl_put_online_on_ack
&&
clientHasPendingReplies
(
slave
))
{
writeToClient
(
slave
->
fd
,
slave
,
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