summaryrefslogtreecommitdiffstats
path: root/lib/libarchive/archive_entry.c
diff options
context:
space:
mode:
authorkientzle <kientzle@FreeBSD.org>2004-05-21 09:01:13 +0000
committerkientzle <kientzle@FreeBSD.org>2004-05-21 09:01:13 +0000
commit531e5eb0bef77e5bc170cc7c2ec27f86e7912914 (patch)
treed00956b4bee2a9ebc061c54a91804c23f03933dd /lib/libarchive/archive_entry.c
parent418aa56fe430321380ae1e15b511efa56ddedd63 (diff)
downloadFreeBSD-src-531e5eb0bef77e5bc170cc7c2ec27f86e7912914.zip
FreeBSD-src-531e5eb0bef77e5bc170cc7c2ec27f86e7912914.tar.gz
Correct parsing of Solaris default ACLs.
Diffstat (limited to 'lib/libarchive/archive_entry.c')
-rw-r--r--lib/libarchive/archive_entry.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/lib/libarchive/archive_entry.c b/lib/libarchive/archive_entry.c
index 89136f7..b7412f4 100644
--- a/lib/libarchive/archive_entry.c
+++ b/lib/libarchive/archive_entry.c
@@ -1058,11 +1058,13 @@ __archive_entry_acl_parse_w(struct archive_entry *entry,
if (sep != L':')
goto fail;
- if (prefix_w(start, end, L"default")) {
+ /*
+ * Solaris extension: "defaultuser::rwx" is the
+ * default ACL corresponding to "user::rwx", etc.
+ */
+ if (end-start > 7 && wmemcmp(start, L"default", 7) == 0) {
type = ARCHIVE_ENTRY_ACL_TYPE_DEFAULT;
- next_field_w(&text, &start, &end, &sep);
- if (sep != L':')
- goto fail;
+ start += 7;
} else
type = default_type;
OpenPOWER on IntegriCloud