Call propagate instead of writing directly to AOF/replicas (#6658)
Use higher-level API to funnel all generic propagation through single function call.
This commit is contained in:
parent
7af05f07ff
commit
b55c1602b5
4
src/db.c
4
src/db.c
@ -1228,9 +1228,7 @@ void propagateExpire(redisDb *db, robj *key, int lazy) {
|
|||||||
incrRefCount(argv[0]);
|
incrRefCount(argv[0]);
|
||||||
incrRefCount(argv[1]);
|
incrRefCount(argv[1]);
|
||||||
|
|
||||||
if (server.aof_state != AOF_OFF)
|
propagate(server.delCommand,db->id,argv,2,PROPAGATE_AOF|PROPAGATE_REPL);
|
||||||
feedAppendOnlyFile(server.delCommand,db->id,argv,2);
|
|
||||||
replicationFeedSlaves(server.slaves,db->id,argv,2);
|
|
||||||
|
|
||||||
decrRefCount(argv[0]);
|
decrRefCount(argv[0]);
|
||||||
decrRefCount(argv[1]);
|
decrRefCount(argv[1]);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user