From dbc6e9a1ef06eb7ea4b8c71b3a292b6571d11a6c Mon Sep 17 00:00:00 2001 From: antirez Date: Fri, 17 Oct 2014 10:21:18 +0200 Subject: [PATCH] Diskless replication: don't enter the read-payload branch forever. --- src/replication.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/replication.c b/src/replication.c index 19f992e0..8fe57e15 100644 --- a/src/replication.c +++ b/src/replication.c @@ -858,6 +858,9 @@ void readSyncBulkPayload(aeEventLoop *el, int fd, void *privdata, int mask) { usemark = 1; memcpy(eofmark,buf+5,REDIS_RUN_ID_SIZE); memset(lastbytes,0,REDIS_RUN_ID_SIZE); + /* Set any repl_transfer_size to avoid entering this code path + * at the next call. */ + server.repl_transfer_size = 0; redisLog(REDIS_NOTICE, "MASTER <-> SLAVE sync: receiving streamed RDB from master"); } else { -- GitLab