diff options
author | David Oberhollenzer <david.oberhollenzer@sigma-star.at> | 2019-12-15 02:30:55 +0100 |
---|---|---|
committer | David Oberhollenzer <david.oberhollenzer@sigma-star.at> | 2019-12-15 02:31:54 +0100 |
commit | 724524cd401325120de9d96e6a1023c3561c8879 (patch) | |
tree | 9219c790cc416664a702e47804304a858829ad0d /lib | |
parent | 5cb28dc91a2e23e6f8f7e875e2ea725634526dfe (diff) |
Fix tar GNU sparse header parsing
Extract the filename correctly.
Signed-off-by: David Oberhollenzer <david.oberhollenzer@sigma-star.at>
Diffstat (limited to 'lib')
-rw-r--r-- | lib/tar/read_header.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/tar/read_header.c b/lib/tar/read_header.c index 20e7a9f..7d209ae 100644 --- a/lib/tar/read_header.c +++ b/lib/tar/read_header.c @@ -160,7 +160,7 @@ static int read_pax_header(FILE *fp, sqfs_u64 entsize, unsigned int *set_by_pax, *set_by_pax |= PAX_MTIME; } else if (!strncmp(line, "GNU.sparse.name=", 16)) { free(out->name); - out->name = strdup(line + 5); + out->name = strdup(line + 16); if (out->name == NULL) goto fail_errno; *set_by_pax |= PAX_NAME; |