aboutsummaryrefslogtreecommitdiff
path: root/archival/tar.c
diff options
context:
space:
mode:
authorGlenn L McGrath <bug1@ihug.co.nz>2002-12-08 00:54:33 +0000
committerGlenn L McGrath <bug1@ihug.co.nz>2002-12-08 00:54:33 +0000
commit66125c806518f74a54232206d02e30a39b621232 (patch)
treef7e34d157460ad689c350071a25d19cdd51e1ebb /archival/tar.c
parent346cdb1ddea7d825b29e9dcd73d6f7af8db8598f (diff)
downloadbusybox-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/tar.c')
-rw-r--r--archival/tar.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/archival/tar.c b/archival/tar.c
index 1899ab954..fa1c57512 100644
--- a/archival/tar.c
+++ b/archival/tar.c
@@ -583,13 +583,13 @@ static inline int writeTarFile(const char *tarName, const int verboseFlag,
583#endif /* tar_create */ 583#endif /* tar_create */
584 584
585#ifdef CONFIG_FEATURE_TAR_EXCLUDE 585#ifdef CONFIG_FEATURE_TAR_EXCLUDE
586static const llist_t *append_file_list_to_list(const char *filename, const llist_t *list) 586static llist_t *append_file_list_to_list(const char *filename, llist_t *list)
587{ 587{
588 FILE *src_stream = xfopen(filename, "r"); 588 FILE *src_stream = xfopen(filename, "r");
589 char *line; 589 char *line;
590 while((line = get_line_from_file(src_stream)) != NULL) { 590 while((line = get_line_from_file(src_stream)) != NULL) {
591 chomp(line); 591 chomp(line);
592 list = add_to_list(list, line); 592 list = llist_add_to(list, line);
593 } 593 }
594 fclose(src_stream); 594 fclose(src_stream);
595 595
@@ -708,7 +708,7 @@ int tar_main(int argc, char **argv)
708 /* Setup an array of filenames to work with */ 708 /* Setup an array of filenames to work with */
709 /* TODO: This is the same as in ar, seperate function ? */ 709 /* TODO: This is the same as in ar, seperate function ? */
710 while (optind < argc) { 710 while (optind < argc) {
711 tar_handle->accept = add_to_list(tar_handle->accept, argv[optind]); 711 tar_handle->accept = llist_add_to(tar_handle->accept, argv[optind]);
712 optind++; 712 optind++;
713 } 713 }
714 714