summaryrefslogtreecommitdiff
path: root/archival/unzip.c
diff options
context:
space:
mode:
authorBernhard Reutner-Fischer2006-04-12 18:39:58 +0000
committerBernhard Reutner-Fischer2006-04-12 18:39:58 +0000
commitd9cf7ac781c1274d6d23fa5674b6b90baaf4cf61 (patch)
treec7e395cfe1eafcd601bc16e0231fc30f8789e4d9 /archival/unzip.c
parent67f641e75b685abe1588b634b409c1ee2ff68c22 (diff)
downloadbusybox-d9cf7ac781c1274d6d23fa5674b6b90baaf4cf61.zip
busybox-d9cf7ac781c1274d6d23fa5674b6b90baaf4cf61.tar.gz
- patch from Denis Vlasenko to add and use bb_xchdir()
Diffstat (limited to 'archival/unzip.c')
-rw-r--r--archival/unzip.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/archival/unzip.c b/archival/unzip.c
index bb7197d..b9dff19 100644
--- a/archival/unzip.c
+++ b/archival/unzip.c
@@ -236,9 +236,8 @@ int unzip_main(int argc, char **argv)
}
/* Change dir if necessary */
- if (base_dir && chdir(base_dir)) {
- bb_perror_msg_and_die("Cannot chdir");
- }
+ if (base_dir)
+ bb_xchdir(base_dir);
if (verbosity != v_silent)
printf("Archive: %s\n", src_fn);