From 3c32344a41b1c9a7d6daccc2c54cf70b4dfd4d5b Mon Sep 17 00:00:00 2001 From: amallia Date: Thu, 15 Jun 2017 20:56:12 +0100 Subject: Small fixes --- hiredis.c | 3 +-- net.c | 1 - 2 files changed, 1 insertion(+), 3 deletions(-) diff --git a/hiredis.c b/hiredis.c index 18bdfc9..3a7ab11 100644 --- a/hiredis.c +++ b/hiredis.c @@ -1007,9 +1007,8 @@ void *redisvCommand(redisContext *c, const char *format, va_list ap) { void *redisCommand(redisContext *c, const char *format, ...) { va_list ap; - void *reply = NULL; va_start(ap,format); - reply = redisvCommand(c,format,ap); + void *reply = redisvCommand(c,format,ap); va_end(ap); return reply; } diff --git a/net.c b/net.c index 024f645..53e59ef 100644 --- a/net.c +++ b/net.c @@ -143,7 +143,6 @@ int redisKeepAlive(redisContext *c, int interval) { } #else #if defined(__GLIBC__) && !defined(__FreeBSD_kernel__) - val = interval; if (setsockopt(fd, IPPROTO_TCP, TCP_KEEPIDLE, &val, sizeof(val)) < 0) { __redisSetError(c,REDIS_ERR_OTHER,strerror(errno)); return REDIS_ERR; -- cgit v1.2.3