diff --git a/src/ll.c b/src/ll.c index 599ec30..08a4b3c 100644 --- a/src/ll.c +++ b/src/ll.c @@ -116,7 +116,7 @@ void* ll_poptail(ll* ll) { void ll_clear(ll* ll){ ll_node* head = ll->head; - while(ll->head){ + while(head){ ll_node* to_free = head; head = head->next; free(to_free);