diff options
author | vda <vda@69ca8d6d-28ef-0310-b511-8ec308f3f277> | 2006-10-05 10:17:08 +0000 |
---|---|---|
committer | vda <vda@69ca8d6d-28ef-0310-b511-8ec308f3f277> | 2006-10-05 10:17:08 +0000 |
commit | c2a198d4d1552b349750a13d2c22486e99ef6270 (patch) | |
tree | 20db60b3a787cd3152160fb60206922fd5eb18ed /libbb/llist.c | |
parent | d8cf793135eac928e653eb5178894a611aa27837 (diff) | |
download | busybox-w32-c2a198d4d1552b349750a13d2c22486e99ef6270.tar.gz busybox-w32-c2a198d4d1552b349750a13d2c22486e99ef6270.tar.bz2 busybox-w32-c2a198d4d1552b349750a13d2c22486e99ef6270.zip |
build system overhaul
git-svn-id: svn://busybox.net/trunk/busybox@16307 69ca8d6d-28ef-0310-b511-8ec308f3f277
Diffstat (limited to 'libbb/llist.c')
-rw-r--r-- | libbb/llist.c | 8 |
1 files changed, 0 insertions, 8 deletions
diff --git a/libbb/llist.c b/libbb/llist.c index 0e727c496..8bf89a595 100644 --- a/libbb/llist.c +++ b/libbb/llist.c | |||
@@ -13,7 +13,6 @@ | |||
13 | #include <stdlib.h> | 13 | #include <stdlib.h> |
14 | #include "libbb.h" | 14 | #include "libbb.h" |
15 | 15 | ||
16 | #ifdef L_llist_add_to | ||
17 | /* Add data to the start of the linked list. */ | 16 | /* Add data to the start of the linked list. */ |
18 | void llist_add_to(llist_t **old_head, void *data) | 17 | void llist_add_to(llist_t **old_head, void *data) |
19 | { | 18 | { |
@@ -22,9 +21,7 @@ void llist_add_to(llist_t **old_head, void *data) | |||
22 | new_head->link = *old_head; | 21 | new_head->link = *old_head; |
23 | *old_head = new_head; | 22 | *old_head = new_head; |
24 | } | 23 | } |
25 | #endif | ||
26 | 24 | ||
27 | #ifdef L_llist_add_to_end | ||
28 | /* Add data to the end of the linked list. */ | 25 | /* Add data to the end of the linked list. */ |
29 | void llist_add_to_end(llist_t **list_head, void *data) | 26 | void llist_add_to_end(llist_t **list_head, void *data) |
30 | { | 27 | { |
@@ -39,9 +36,7 @@ void llist_add_to_end(llist_t **list_head, void *data) | |||
39 | tail->link = new_item; | 36 | tail->link = new_item; |
40 | } | 37 | } |
41 | } | 38 | } |
42 | #endif | ||
43 | 39 | ||
44 | #ifdef L_llist_pop | ||
45 | /* Remove first element from the list and return it */ | 40 | /* Remove first element from the list and return it */ |
46 | void *llist_pop(llist_t **head) | 41 | void *llist_pop(llist_t **head) |
47 | { | 42 | { |
@@ -57,9 +52,7 @@ void *llist_pop(llist_t **head) | |||
57 | 52 | ||
58 | return data; | 53 | return data; |
59 | } | 54 | } |
60 | #endif | ||
61 | 55 | ||
62 | #ifdef L_llist_free | ||
63 | /* Recursively free all elements in the linked list. If freeit != NULL | 56 | /* Recursively free all elements in the linked list. If freeit != NULL |
64 | * call it on each datum in the list */ | 57 | * call it on each datum in the list */ |
65 | void llist_free(llist_t *elm, void (*freeit)(void *data)) | 58 | void llist_free(llist_t *elm, void (*freeit)(void *data)) |
@@ -69,4 +62,3 @@ void llist_free(llist_t *elm, void (*freeit)(void *data)) | |||
69 | if (freeit) freeit(data); | 62 | if (freeit) freeit(data); |
70 | } | 63 | } |
71 | } | 64 | } |
72 | #endif | ||