diff --git a/doubly_linked_list_with_iterator.c b/doubly_linked_list_with_iterator.c index 6295cfc..028745a 100644 --- a/doubly_linked_list_with_iterator.c +++ b/doubly_linked_list_with_iterator.c @@ -285,10 +285,10 @@ void list_insert(IntList list, int value) { list->tail->next = newNode; newNode->prev = list->tail; } - } - list->tail = newNode; - list->size++; + list->tail = newNode; + list->size++; + } } /**