diff --git a/src/ordinary.c b/src/ordinary.c new file mode 100644 index 0000000..70eeab5 --- /dev/null +++ b/src/ordinary.c @@ -0,0 +1,19 @@ +#include +#include + +void ordinary_list_new(struct ordinary_list *list, uint32_t limit) { + list->head = NULL; + list->tail = NULL; + list->count = 0; + list->limit = limit; +} + +void ordinary_list_del(struct ordinary_list *list) { + struct ordinary_node *at = list->head; + + while(at) { + struct ordinary_node *next = at->next; + free(at); + at = next; + } +}