From 5b8e0b13427b0fc6d9bda83fb115abfac509bfb4 Mon Sep 17 00:00:00 2001 From: Eaden McKee <_@eaden.net> Date: Mon, 1 Jun 2015 23:21:43 +1000 Subject: [PATCH] fix possible typo/logic error --- redis/hiredis.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/redis/hiredis.c b/redis/hiredis.c index 28f83c9..9fadea3 100644 --- a/redis/hiredis.c +++ b/redis/hiredis.c @@ -78,7 +78,7 @@ int hiredis_odb_backend__read_header(size_t *len_p, git_otype *type_p, git_odb_b if (reply && reply->type == REDIS_REPLY_ARRAY) { if (reply->element[0]->type != REDIS_REPLY_NIL && - reply->element[0]->type != REDIS_REPLY_NIL) { + reply->element[1]->type != REDIS_REPLY_NIL) { *type_p = (git_otype) atoi(reply->element[0]->str); *len_p = (size_t) atoi(reply->element[1]->str); error = GIT_OK; @@ -595,4 +595,3 @@ int git_refdb_backend_hiredis(git_refdb_backend **backend_out, const char* prefi return GIT_OK; } -