summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatt Kraai2001-05-22 14:18:03 +0000
committerMatt Kraai2001-05-22 14:18:03 +0000
commit7f7348b7b2ae134d1e958c04b3123b573dec8b70 (patch)
treea7f69bf3858ef3bee7e252e04487aef364a2e857
parent1d9d41150bea7e89a881eeee7f71f88ae1fc2381 (diff)
downloadbusybox-7f7348b7b2ae134d1e958c04b3123b573dec8b70.zip
busybox-7f7348b7b2ae134d1e958c04b3123b573dec8b70.tar.gz
Correctly remove leading slashes upon extraction (thanks to Marius Groeger).
-rw-r--r--archival/tar.c2
-rw-r--r--tar.c2
2 files changed, 2 insertions, 2 deletions
diff --git a/archival/tar.c b/archival/tar.c
index 6af16f4..282656f 100644
--- a/archival/tar.c
+++ b/archival/tar.c
@@ -490,7 +490,7 @@ readTarHeader(struct TarHeader *rawHeader, struct TarInfo *header)
static int alreadyWarned=FALSE;
while (*(header->name) == '/')
- ++*(header->name);
+ header->name++;
if (alreadyWarned == FALSE) {
error_msg("Removing leading '/' from member names");
diff --git a/tar.c b/tar.c
index 6af16f4..282656f 100644
--- a/tar.c
+++ b/tar.c
@@ -490,7 +490,7 @@ readTarHeader(struct TarHeader *rawHeader, struct TarInfo *header)
static int alreadyWarned=FALSE;
while (*(header->name) == '/')
- ++*(header->name);
+ header->name++;
if (alreadyWarned == FALSE) {
error_msg("Removing leading '/' from member names");