Compare commits

...

1 Commits

Author SHA1 Message Date
Alexis Campailla
7796c039cb Fix redis-cli pipe mode
Pipe mode was broken due to CRT's translation of CRLF sequences.
2015-01-02 17:48:09 -05:00

View File

@@ -1246,6 +1246,11 @@ static void pipeMode(void) {
char magic[20]; /* Special reply we recognize. */
time_t last_read_time = time(NULL);
#ifdef _WIN32
/* Prevent translation or CRLF sequences. */
setmode(STDIN_FILENO,_O_BINARY);
#endif
srand((unsigned int)time(NULL));
/* Use non blocking I/O. */