aboutsummaryrefslogtreecommitdiff
path: root/libbb
diff options
context:
space:
mode:
authorbug1 <bug1@69ca8d6d-28ef-0310-b511-8ec308f3f277>2001-04-21 02:12:13 +0000
committerbug1 <bug1@69ca8d6d-28ef-0310-b511-8ec308f3f277>2001-04-21 02:12:13 +0000
commit5e82aad4ea026bf219b2542c061596cdc6a583df (patch)
treeb7159867025cc63f664a395dcdfb18d4f37d8922 /libbb
parent9aeb8b2faa27d4e2e415b39cdcd7cd4bb375790d (diff)
downloadbusybox-w32-5e82aad4ea026bf219b2542c061596cdc6a583df.tar.gz
busybox-w32-5e82aad4ea026bf219b2542c061596cdc6a583df.tar.bz2
busybox-w32-5e82aad4ea026bf219b2542c061596cdc6a583df.zip
Clearly define out exclude list code, as recommended by Larry Doolittle
git-svn-id: svn://busybox.net/trunk/busybox@2396 69ca8d6d-28ef-0310-b511-8ec308f3f277
Diffstat (limited to 'libbb')
-rw-r--r--libbb/untar.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/libbb/untar.c b/libbb/untar.c
index a77d94f61..70f7eb6a6 100644
--- a/libbb/untar.c
+++ b/libbb/untar.c
@@ -103,7 +103,8 @@ extern char *untar(FILE *src_tar_file, FILE *output, const int untar_function,
103 next_header_offset += (512 - size % 512); 103 next_header_offset += (512 - size % 512);
104 } 104 }
105 105
106 /* If an exclude list is specified check current file against list 106 /* If an exclude list is specified check current file against list */
107#if 0
107 if (*exclude_list != NULL) { 108 if (*exclude_list != NULL) {
108 i = 0; 109 i = 0;
109 while (exclude_list[i] != 0) { 110 while (exclude_list[i] != 0) {
@@ -115,8 +116,8 @@ extern char *untar(FILE *src_tar_file, FILE *output, const int untar_function,
115 if (exclude_list[i] != 0) { 116 if (exclude_list[i] != 0) {
116 continue; 117 continue;
117 } 118 }
118 } */ 119 }
119 120#endif
120 if (untar_function & (extract_contents | extract_verbose_extract | extract_contents_to_file)) { 121 if (untar_function & (extract_contents | extract_verbose_extract | extract_contents_to_file)) {
121 fprintf(output, "%s\n", raw_tar_header.name); 122 fprintf(output, "%s\n", raw_tar_header.name);
122 } 123 }
@@ -152,7 +153,7 @@ extern char *untar(FILE *src_tar_file, FILE *output, const int untar_function,
152 strcat(file_name, "."); 153 strcat(file_name, ".");
153 strcat(file_name, file_extension); 154 strcat(file_name, file_extension);
154 155
155 full_name = concat_path_file(strndup(dir, strlen(dir) - strlen(strrchr(dir, '/'))), file_name); 156 full_name = concat_path_file(xstrndup(dir, strlen(dir) - strlen(strrchr(dir, '/'))), file_name);
156 } else { 157 } else {
157 full_name = xstrdup(dir); 158 full_name = xstrdup(dir);
158 } 159 }