redisBufferRead: Clear REDIS_CONNECTED flag when server closed connection

This commit is contained in:
Jerry Jacobs 2015-05-26 13:36:07 +02:00 committed by Jan-Erik Rediger
parent 8e6d8195a9
commit 1db17f257b

View File

@ -808,6 +808,7 @@ int redisBufferRead(redisContext *c) {
return REDIS_ERR; return REDIS_ERR;
} }
} else if (nread == 0) { } else if (nread == 0) {
c->flags &= ~REDIS_CONNECTED;
__redisSetError(c,REDIS_ERR_EOF,"Server closed the connection"); __redisSetError(c,REDIS_ERR_EOF,"Server closed the connection");
return REDIS_ERR; return REDIS_ERR;
} else { } else {