1
0
mirror of https://github.com/fluencelabs/redis synced 2025-06-26 23:41:33 +00:00

fixed bgsave_in_progress in INFO when BGSAVEing with diskstore enabled, don't DEBUG FLUSHCACHE when bgsave is in progress.

This commit is contained in:
antirez
2011-01-09 19:25:34 +01:00
parent 0a0f83ab2c
commit a5062bbab0
4 changed files with 13 additions and 10 deletions

@ -181,6 +181,9 @@ void debugCommand(redisClient *c) {
if (!server.ds_enabled) {
addReplyError(c, "DEBUG FLUSHCACHE called with diskstore off.");
return;
} else if (server.bgsavethread != (pthread_t) -1) {
addReplyError(c, "Can't flush cache while BGSAVE is in progress.");
return;
} else {
/* To flush the whole cache we need to wait for everything to
* be flushed on disk... */