diff options
author | mm <mm@FreeBSD.org> | 2011-12-21 15:02:37 +0000 |
---|---|---|
committer | mm <mm@FreeBSD.org> | 2011-12-21 15:02:37 +0000 |
commit | 8ee1bd70e81572c768fd0abc35dc7de2f200c15c (patch) | |
tree | cd57684ad0e363877d19ea870b6bca4363414453 /contrib/libarchive | |
parent | 75da7f804c79a9b24b96c541ff4e9604e821afe9 (diff) | |
download | FreeBSD-src-8ee1bd70e81572c768fd0abc35dc7de2f200c15c.zip FreeBSD-src-8ee1bd70e81572c768fd0abc35dc7de2f200c15c.tar.gz |
Partial merge of r224691 from lib/libarchive:
Add compatibility for ISO images created with unfixed makefs that
violated ECMA-119 (ISO9660): allow reserved4 to be 0x20 in PVD.
This allows tar to read FreeBSD distribution ISO images created
with makefs prior to NetBSD bin/45217 bugfix (up to 9.0-BETA1).
MFC after: 2 weeks
Diffstat (limited to 'contrib/libarchive')
-rw-r--r-- | contrib/libarchive/libarchive/archive_read_support_format_iso9660.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/contrib/libarchive/libarchive/archive_read_support_format_iso9660.c b/contrib/libarchive/libarchive/archive_read_support_format_iso9660.c index fb61203..516b844 100644 --- a/contrib/libarchive/libarchive/archive_read_support_format_iso9660.c +++ b/contrib/libarchive/libarchive/archive_read_support_format_iso9660.c @@ -895,8 +895,10 @@ isPVD(struct iso9660 *iso9660, const unsigned char *h) return (0); /* Reserved field must be 0. */ + /* FreeBSD: makefs erroneously created images with 0x20 */ for (i = 0; i < PVD_reserved4_size; ++i) - if (h[PVD_reserved4_offset + i] != 0) + if (h[PVD_reserved4_offset + i] != 0 && + h[PVD_reserved4_offset + i] != 32) return (0); /* Reserved field must be 0. */ |