make sure to flush stdout every line read in monitor mode, to play well with redirection to file

This commit is contained in:
antirez 2010-11-08 16:14:15 +01:00
parent 5402c4262e
commit d9d8ccab93

View File

@ -291,6 +291,7 @@ static int cliSendCommand(int argc, char **argv, int repeat) {
redisAppendCommandArgv(context,argc,(const char**)argv,argvlen);
while (config.monitor_mode) {
if (cliReadReply() != REDIS_OK) exit(1);
fflush(stdout);
}
if (config.pubsub_mode) {