aboutsummaryrefslogtreecommitdiff
path: root/libs/libc/list.c
diff options
context:
space:
mode:
Diffstat (limited to 'libs/libc/list.c')
-rw-r--r--libs/libc/list.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libs/libc/list.c b/libs/libc/list.c
index 3f37478..a477285 100644
--- a/libs/libc/list.c
+++ b/libs/libc/list.c
@@ -61,7 +61,7 @@ NONNULL static struct node *list_add_node(struct list *list, struct node *node)
struct node *list_last(struct list *list)
{
- if (list->head)
+ if (!list->head)
return NULL;
struct node *iterator = list->head;