]> git.saurik.com Git - redis.git/commitdiff
Check that we have connection before enabling pipe mode
authorSteeve Lennmark <steevel@handeldsbanken.se>
Sun, 15 Jul 2012 12:35:02 +0000 (14:35 +0200)
committerSteeve Lennmark <steevel@handeldsbanken.se>
Sun, 15 Jul 2012 12:35:02 +0000 (14:35 +0200)
src/redis-cli.c

index 97caf5be8103e582cf35661bfe62c48a7eba1d06..8d20d1cd502ebfd7c53793914a3a9a5477c9db8a 100644 (file)
@@ -1233,7 +1233,7 @@ int main(int argc, char **argv) {
 
     /* Pipe mode */
     if (config.pipe_mode) {
-        cliConnect(0);
+        if (cliConnect(0) == REDIS_ERR) exit(1);
         pipeMode();
     }