diff options
author | antirez <antirez@gmail.com> | 2010-11-08 16:32:51 +0100 |
---|---|---|
committer | antirez <antirez@gmail.com> | 2010-11-08 16:32:51 +0100 |
commit | f7ba093969f432b03fd846a6a61fd9b6986c8823 (patch) | |
tree | 09d11fddc9dd6e244574556ab7568a7bab99ddba | |
parent | 1c14507366d0026eecc50530664b4dd58cd3eaa5 (diff) | |
download | redis-f7ba093969f432b03fd846a6a61fd9b6986c8823.tar.gz |
make sure to flush stdout every line read in monitor mode, to play well with redirection to file
-rw-r--r-- | redis-cli.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/redis-cli.c b/redis-cli.c index 96d1ae50a..01a68624d 100644 --- a/redis-cli.c +++ b/redis-cli.c @@ -304,6 +304,7 @@ static int cliSendCommand(int argc, char **argv, int repeat) { while (config.monitor_mode) { if (cliReadSingleLineReply(fd,0)) exit(1); printf("\n"); + fflush(stdout); } if (config.pubsub_mode) { |