summaryrefslogtreecommitdiff
path: root/archivers/libarchive/files/tar/util.c
diff options
context:
space:
mode:
Diffstat (limited to 'archivers/libarchive/files/tar/util.c')
-rw-r--r--archivers/libarchive/files/tar/util.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/archivers/libarchive/files/tar/util.c b/archivers/libarchive/files/tar/util.c
index 9ff22f2b615..662db5baa79 100644
--- a/archivers/libarchive/files/tar/util.c
+++ b/archivers/libarchive/files/tar/util.c
@@ -140,6 +140,7 @@ safe_fprintf(FILE *f, const char *fmt, ...)
} else {
/* Leave fmtbuff pointing to the truncated
* string in fmtbuff_stack. */
+ fmtbuff = fmtbuff_stack;
length = sizeof(fmtbuff_stack) - 1;
break;
}
@@ -182,7 +183,7 @@ safe_fprintf(FILE *f, const char *fmt, ...)
}
/* If our output buffer is full, dump it and keep going. */
- if (i > (sizeof(outbuff) - 20)) {
+ if (i > (sizeof(outbuff) - 128)) {
outbuff[i] = '\0';
fprintf(f, "%s", outbuff);
i = 0;
@@ -533,7 +534,7 @@ edit_pathname(struct bsdtar *bsdtar, struct archive_entry *entry)
}
}
- if (!bsdtar->option_absolute_paths) {
+ if ((bsdtar->flags & OPTFLAG_ABSOLUTE_PATHS) == 0) {
/* By default, don't write or restore absolute pathnames. */
name = strip_absolute_path(bsdtar, name);
if (*name == '\0')