]> git.saurik.com Git - redis.git/commitdiff
FLUSHALL will only perform a blocking SAVE if RDB persistence is configured.
authorantirez <antirez@gmail.com>
Mon, 17 Oct 2011 08:25:35 +0000 (10:25 +0200)
committerantirez <antirez@gmail.com>
Mon, 17 Oct 2011 08:31:34 +0000 (10:31 +0200)
src/db.c

index 9620b6e8f640f10cbecf6172642aadc2d9be2de2..40b8148c3ab338537c7f871622edc8595c14e9c5 100644 (file)
--- a/src/db.c
+++ b/src/db.c
@@ -213,7 +213,7 @@ void flushallCommand(redisClient *c) {
         kill(server.bgsavechildpid,SIGKILL);
         rdbRemoveTempFile(server.bgsavechildpid);
     }
-    rdbSave(server.dbfilename);
+    if (server.saveparamslen > 0) rdbSave(server.dbfilename);
     server.dirty++;
 }