]> git.ipfire.org Git - thirdparty/freeradius-server.git/commitdiff
...and more redis fixes.
authorArran Cudbard-Bell <a.cudbardb@freeradius.org>
Mon, 21 Nov 2016 21:59:34 +0000 (16:59 -0500)
committerArran Cudbard-Bell <a.cudbardb@freeradius.org>
Tue, 22 Nov 2016 12:52:50 +0000 (07:52 -0500)
src/modules/rlm_redis_ippool/rlm_redis_ippool_tool.c

index 01b77a88d245aec68c65a9adbede7413b15ec447..eaf1e6fd7110718e0c5a0a29e18c6bda06b514ed 100644 (file)
@@ -1108,7 +1108,7 @@ static int driver_get_stats(ippool_tool_stats_t *out, void *instance, uint8_t co
                goto error;
        }
 
-       reply = replies[pipelined - 1];
+       reply = replies[reply_cnt - 1];
 
        if (reply->type != REDIS_REPLY_ARRAY) {
                ERROR("Failed retrieving pool stats: Expected array got %s",
@@ -1116,8 +1116,8 @@ static int driver_get_stats(ippool_tool_stats_t *out, void *instance, uint8_t co
                goto error;
        }
 
-       if (reply->elements != (pipelined - 2)) {
-               ERROR("Failed retrieving pool stats: Expected %i results, got %zu", pipelined - 2, reply->elements);
+       if (reply->elements != (reply_cnt - 2)) {
+               ERROR("Failed retrieving pool stats: Expected %i results, got %zu", reply_cnt - 2, reply->elements);
                goto error;
        }