From bc2a047d4475afe2334fb1b37cd417997284bb6d Mon Sep 17 00:00:00 2001 From: phfr24 Date: Sun, 1 Mar 2026 00:08:23 -0300 Subject: [PATCH] simplify queue_has() --- queue/queue.c | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/queue/queue.c b/queue/queue.c index 1f5d3a7..13c43b4 100644 --- a/queue/queue.c +++ b/queue/queue.c @@ -164,12 +164,7 @@ queue_has (struct queue_t *queue, void *item) while (n->item != item && (n = n->next)) ; - if (!n) - { - return false; - } - - return true; + return n != NULL; } int -- 2.52.0