From: Tim Kientzle Date: Sun, 14 Feb 2016 05:52:24 +0000 (-0800) Subject: Issue #659: Fix xar parsing of archives with appleextended ACLs X-Git-Tag: v3.1.900a~3 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=450b1f55328df0dd8294859e37ca66c0f382f614;p=thirdparty%2Flibarchive.git Issue #659: Fix xar parsing of archives with appleextended ACLs The parser treated the tag as both known and unknown, leaving the parser in a state that prevented it from reading any further attributes. Depending on the order of attributes, this could result in a file with no name, for instance. --- diff --git a/libarchive/archive_read_support_format_xar.c b/libarchive/archive_read_support_format_xar.c index 19c1b780e..40308984e 100644 --- a/libarchive/archive_read_support_format_xar.c +++ b/libarchive/archive_read_support_format_xar.c @@ -2168,7 +2168,7 @@ xml_start(struct archive_read *a, const char *name, struct xmlattr_list *list) case FILE_ACL: if (strcmp(name, "appleextended") == 0) xar->xmlsts = FILE_ACL_APPLEEXTENDED; - if (strcmp(name, "default") == 0) + else if (strcmp(name, "default") == 0) xar->xmlsts = FILE_ACL_DEFAULT; else if (strcmp(name, "access") == 0) xar->xmlsts = FILE_ACL_ACCESS;