summaryrefslogtreecommitdiff
path: root/usr.bin
diff options
context:
space:
mode:
authorTim Kientzle <kientzle@FreeBSD.org>2007-08-25 04:38:44 +0000
committerTim Kientzle <kientzle@FreeBSD.org>2007-08-25 04:38:44 +0000
commitb349865b64c436e15f118652eecc666b1085b627 (patch)
treebbe935b8b1f53b6d5a946a14f305ba3dcfc65256 /usr.bin
parentbcf9d1d440068c7a816a5fb127f3ac23c9f21a0e (diff)
Notes
Diffstat (limited to 'usr.bin')
-rw-r--r--usr.bin/tar/Makefile2
-rw-r--r--usr.bin/tar/bsdtar.c15
2 files changed, 10 insertions, 7 deletions
diff --git a/usr.bin/tar/Makefile b/usr.bin/tar/Makefile
index 063d6ea024cd..face5dbae206 100644
--- a/usr.bin/tar/Makefile
+++ b/usr.bin/tar/Makefile
@@ -1,7 +1,7 @@
# $FreeBSD$
PROG= bsdtar
-VERSION= 1.9.2
+VERSION= 1.9.3
SRCS= bsdtar.c getdate.y matching.c read.c tree.c util.c write.c
WARNS?= 5
DPADD= ${LIBARCHIVE} ${LIBBZ2} ${LIBZ}
diff --git a/usr.bin/tar/bsdtar.c b/usr.bin/tar/bsdtar.c
index faec8ec8b0de..03c64182a66c 100644
--- a/usr.bin/tar/bsdtar.c
+++ b/usr.bin/tar/bsdtar.c
@@ -270,6 +270,11 @@ main(int argc, char **argv)
if (bsdtar->user_uid == 0) {
/* --same-owner */
bsdtar->extract_flags |= ARCHIVE_EXTRACT_OWNER;
+ /* -p */
+ bsdtar->extract_flags |= ARCHIVE_EXTRACT_PERM;
+ bsdtar->extract_flags |= ARCHIVE_EXTRACT_ACL;
+ bsdtar->extract_flags |= ARCHIVE_EXTRACT_XATTR;
+ bsdtar->extract_flags |= ARCHIVE_EXTRACT_FFLAGS;
}
/* Rewrite traditional-style tar arguments, if used. */
@@ -438,12 +443,10 @@ main(int argc, char **argv)
bsdtar->extract_flags &= ~ARCHIVE_EXTRACT_OWNER;
break;
case OPTION_NO_SAME_PERMISSIONS: /* GNU tar */
- /*
- * This is always the default in FreeBSD's
- * version of GNU tar; it's also the default
- * behavior for bsdtar, so treat the
- * command-line option as a no-op.
- */
+ bsdtar->extract_flags &= ~ARCHIVE_EXTRACT_PERM;
+ bsdtar->extract_flags &= ~ARCHIVE_EXTRACT_ACL;
+ bsdtar->extract_flags &= ~ARCHIVE_EXTRACT_XATTR;
+ bsdtar->extract_flags &= ~ARCHIVE_EXTRACT_FFLAGS;
break;
case OPTION_NULL: /* GNU tar */
bsdtar->option_null++;