summaryrefslogtreecommitdiff
path: root/src/sync-mode.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/sync-mode.c')
-rw-r--r--src/sync-mode.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/sync-mode.c b/src/sync-mode.c
index 74eb36e..866b313 100644
--- a/src/sync-mode.c
+++ b/src/sync-mode.c
@@ -466,6 +466,16 @@ static int local_handler_sync(int fd, int type, void *data)
cache_flush(STATE_SYNC(internal));
cache_flush(STATE_SYNC(external));
break;
+ case FLUSH_INT_CACHE:
+ /* inmediate flush, remove pending flush scheduled if any */
+ del_alarm(&STATE_SYNC(reset_cache_alarm));
+ dlog(LOG_NOTICE, "flushing internal cache");
+ cache_flush(STATE_SYNC(internal));
+ break;
+ case FLUSH_EXT_CACHE:
+ dlog(LOG_NOTICE, "flushing external cache");
+ cache_flush(STATE_SYNC(external));
+ break;
case KILL:
killer(0);
break;