From 469f5a7da371553740453847c3af1be7dd824d6c Mon Sep 17 00:00:00 2001 From: orange Date: Tue, 2 Jul 2013 18:19:50 +0200 Subject: [PATCH] make the list a type itself --- linked-list.c | 1 + 1 file changed, 1 insertion(+) diff --git a/linked-list.c b/linked-list.c index 6a6d8d7..f923297 100644 --- a/linked-list.c +++ b/linked-list.c @@ -94,6 +94,7 @@ int main(int argc, char *argv[]) { printf("list_length = %d\n", list_length(emptylist)); list_t *foolist = malloc(sizeof(list_t)); + list_init(foolist); list_node_t foo = { 1, NULL }; list_add(foolist, &foo);