Fix leaking stale RDBs during multimaster sync

Former-commit-id: e1c96209510b374e644e5d7e7b6a009ed0f27c32
This commit is contained in:
John Sully 2019-09-27 13:17:29 -04:00
parent 4f19c5de9f
commit cdfcc42b6d

View File

@ -1553,6 +1553,8 @@ void readSyncBulkPayload(aeEventLoop *el, int fd, void *privdata, int mask) {
return;
}
/* Final setup of the connected slave <- master link */
if (fUpdate)
unlink(mi->repl_transfer_tmpfile); // if we're not updating this became the backup RDB
zfree(mi->repl_transfer_tmpfile);
close(mi->repl_transfer_fd);
replicationCreateMasterClient(mi, mi->repl_transfer_s,rsi.repl_stream_db);