aboutsummaryrefslogtreecommitdiffstats
path: root/contrib/libarchive/libarchive/archive_read_disk_entry_from_file.c
diff options
context:
space:
mode:
authorMartin Matuska <mm@FreeBSD.org>2019-10-09 22:19:48 +0000
committerMartin Matuska <mm@FreeBSD.org>2019-10-09 22:19:48 +0000
commit3c2683a217561866d3134c61c2a3d51e85216df5 (patch)
tree00c2eeffb85a88c860813a683bd72090a42bcda2 /contrib/libarchive/libarchive/archive_read_disk_entry_from_file.c
parent3c4311e020614912a03ffcfdd2ad95e285e34730 (diff)
downloadsrc-3c2683a217561866d3134c61c2a3d51e85216df5.tar.gz
src-3c2683a217561866d3134c61c2a3d51e85216df5.zip
MFC r316456,352732:
Sync libarchive with vendor. MFC r316456: Vendor changes (FreeBSD-related): Report which extended attributes could not be restored Update archive_read_disk.3 and archive_write_disk.3 manual pages Plug memory leaks in xattr tests. MFC r352732: Relevant vendor changes: Issue #1237: Fix integer overflow in archive_read_support_filter_lz4.c PR #1249: Correct some typographical and grammatical errors. PR #1250: Minor corrections to the formatting of manual pages
Notes
Notes: svn path=/stable/10/; revision=353377
Diffstat (limited to 'contrib/libarchive/libarchive/archive_read_disk_entry_from_file.c')
-rw-r--r--contrib/libarchive/libarchive/archive_read_disk_entry_from_file.c16
1 files changed, 14 insertions, 2 deletions
diff --git a/contrib/libarchive/libarchive/archive_read_disk_entry_from_file.c b/contrib/libarchive/libarchive/archive_read_disk_entry_from_file.c
index c89bc384e672..45417e9ac763 100644
--- a/contrib/libarchive/libarchive/archive_read_disk_entry_from_file.c
+++ b/contrib/libarchive/libarchive/archive_read_disk_entry_from_file.c
@@ -616,9 +616,21 @@ setup_xattrs(struct archive_read_disk *a,
}
for (p = list; (p - list) < list_size; p += strlen(p) + 1) {
- if (strncmp(p, "system.", 7) == 0 ||
- strncmp(p, "xfsroot.", 8) == 0)
+#if ARCHIVE_XATTR_LINUX
+ /* Linux: skip POSIX.1e ACL extended attributes */
+ if (strncmp(p, "system.", 7) == 0 &&
+ (strcmp(p + 7, "posix_acl_access") == 0 ||
+ strcmp(p + 7, "posix_acl_default") == 0))
+ continue;
+ if (strncmp(p, "trusted.SGI_", 12) == 0 &&
+ (strcmp(p + 12, "ACL_DEFAULT") == 0 ||
+ strcmp(p + 12, "ACL_FILE") == 0))
continue;
+
+ /* Linux: xfsroot namespace is obsolete and unsupported */
+ if (strncmp(p, "xfsroot.", 8) == 0)
+ continue;
+#endif
setup_xattr(a, entry, p, *fd, path);
}