diff options
author | Glenn L McGrath <bug1@ihug.co.nz> | 2002-12-08 00:54:33 +0000 |
---|---|---|
committer | Glenn L McGrath <bug1@ihug.co.nz> | 2002-12-08 00:54:33 +0000 |
commit | 66125c806518f74a54232206d02e30a39b621232 (patch) | |
tree | f7e34d157460ad689c350071a25d19cdd51e1ebb /archival/libunarchive | |
parent | 346cdb1ddea7d825b29e9dcd73d6f7af8db8598f (diff) | |
download | busybox-w32-66125c806518f74a54232206d02e30a39b621232.tar.gz busybox-w32-66125c806518f74a54232206d02e30a39b621232.tar.bz2 busybox-w32-66125c806518f74a54232206d02e30a39b621232.zip |
Move add_to_list from libunarchive to libbb so it can be of more general use (eg ifupdown). Changed the name to llist_add_to as i plan on adding more llist_ functions as needed (e.g. llist_free).
Diffstat (limited to 'archival/libunarchive')
-rw-r--r-- | archival/libunarchive/Makefile.in | 1 | ||||
-rw-r--r-- | archival/libunarchive/add_to_list.c | 15 | ||||
-rw-r--r-- | archival/libunarchive/get_header_tar.c | 2 |
3 files changed, 1 insertions, 17 deletions
diff --git a/archival/libunarchive/Makefile.in b/archival/libunarchive/Makefile.in index 5675d092f..28e2955b9 100644 --- a/archival/libunarchive/Makefile.in +++ b/archival/libunarchive/Makefile.in | |||
@@ -53,7 +53,6 @@ LIBUNARCHIVE-y:= \ | |||
53 | \ | 53 | \ |
54 | archive_copy_file.o \ | 54 | archive_copy_file.o \ |
55 | \ | 55 | \ |
56 | add_to_list.o \ | ||
57 | check_header_gzip.o \ | 56 | check_header_gzip.o \ |
58 | check_trailer_gzip.o \ | 57 | check_trailer_gzip.o \ |
59 | data_align.o \ | 58 | data_align.o \ |
diff --git a/archival/libunarchive/add_to_list.c b/archival/libunarchive/add_to_list.c deleted file mode 100644 index 052bca351..000000000 --- a/archival/libunarchive/add_to_list.c +++ /dev/null | |||
@@ -1,15 +0,0 @@ | |||
1 | #include <stdlib.h> | ||
2 | #include <string.h> | ||
3 | #include "unarchive.h" | ||
4 | #include "libbb.h" | ||
5 | |||
6 | extern const llist_t *add_to_list(const llist_t *old_head, const char *new_item) | ||
7 | { | ||
8 | llist_t *new_head; | ||
9 | |||
10 | new_head = xmalloc(sizeof(llist_t)); | ||
11 | new_head->data = new_item; | ||
12 | new_head->link = old_head; | ||
13 | |||
14 | return(new_head); | ||
15 | } | ||
diff --git a/archival/libunarchive/get_header_tar.c b/archival/libunarchive/get_header_tar.c index 37e33d4c3..5fed7c1bf 100644 --- a/archival/libunarchive/get_header_tar.c +++ b/archival/libunarchive/get_header_tar.c | |||
@@ -171,7 +171,7 @@ extern char get_header_tar(archive_handle_t *archive_handle) | |||
171 | archive_handle->action_header(archive_handle->file_header); | 171 | archive_handle->action_header(archive_handle->file_header); |
172 | archive_handle->flags |= ARCHIVE_EXTRACT_QUIET; | 172 | archive_handle->flags |= ARCHIVE_EXTRACT_QUIET; |
173 | archive_handle->action_data(archive_handle); | 173 | archive_handle->action_data(archive_handle); |
174 | archive_handle->passed = add_to_list(archive_handle->passed, archive_handle->file_header->name); | 174 | archive_handle->passed = llist_add_to(archive_handle->passed, archive_handle->file_header->name); |
175 | } else { | 175 | } else { |
176 | data_skip(archive_handle); | 176 | data_skip(archive_handle); |
177 | } | 177 | } |