Skip to content

Commit 80f7f63

Browse files
committed
Diskless replication: don't enter the read-payload branch forever.
1 parent f703693 commit 80f7f63

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

src/replication.c

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -864,6 +864,9 @@ void readSyncBulkPayload(aeEventLoop *el, int fd, void *privdata, int mask) {
864864
usemark = 1;
865865
memcpy(eofmark,buf+5,REDIS_RUN_ID_SIZE);
866866
memset(lastbytes,0,REDIS_RUN_ID_SIZE);
867+
/* Set any repl_transfer_size to avoid entering this code path
868+
* at the next call. */
869+
server.repl_transfer_size = 0;
867870
redisLog(REDIS_NOTICE,
868871
"MASTER <-> SLAVE sync: receiving streamed RDB from master");
869872
} else {

0 commit comments

Comments
 (0)