]> git.ipfire.org Git - thirdparty/freeradius-server.git/commitdiff
trunk: Fix bad assert
authorArran Cudbard-Bell <a.cudbardb@freeradius.org>
Wed, 22 Apr 2020 19:26:17 +0000 (14:26 -0500)
committerArran Cudbard-Bell <a.cudbardb@freeradius.org>
Wed, 22 Apr 2020 19:26:24 +0000 (14:26 -0500)
src/lib/server/trunk.c

index 7e3fb189ba36996828887a99ed406986d60b473a..f824d446cdd9c4e9bb918162c8960aeaed2fb640 100644 (file)
@@ -1597,7 +1597,7 @@ static uint64_t trunk_connection_requests_requeue(fr_trunk_connection_t *tconn,
                int ret;
 
                ret = fr_heap_extract(trunk->active, tconn);
-               if (!fr_cond_assert_msg(ret != 0,
+               if (!fr_cond_assert_msg(ret == 0,
                                        "Failed extracting conn from active heap: %s", fr_strerror())) goto done;
 
        }
@@ -1661,7 +1661,7 @@ static uint64_t trunk_connection_requests_requeue(fr_trunk_connection_t *tconn,
                int ret;
 
                ret = fr_heap_insert(trunk->active, tconn);
-               if (!fr_cond_assert_msg(ret != 0,
+               if (!fr_cond_assert_msg(ret == 0,
                                        "Failed re-inserting conn into active heap: %s", fr_strerror())) goto done;
        }
        if (moved >= max) goto done;