Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 1 Feb 2009 02:33:02 +0000 (UTC)
From:      Tim Kientzle <kientzle@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r187975 - head/lib/libarchive
Message-ID:  <200902010233.n112X2fe040569@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: kientzle
Date: Sun Feb  1 02:33:02 2009
New Revision: 187975
URL: http://svn.freebsd.org/changeset/base/187975

Log:
  Permit ` as a pad character in the filename table.
  This seems to fix the devel/zziplib port, which distributes
  its man pages in an ar archive.

Modified:
  head/lib/libarchive/archive_read_support_format_ar.c

Modified: head/lib/libarchive/archive_read_support_format_ar.c
==============================================================================
--- head/lib/libarchive/archive_read_support_format_ar.c	Sun Feb  1 02:04:24 2009	(r187974)
+++ head/lib/libarchive/archive_read_support_format_ar.c	Sun Feb  1 02:33:02 2009	(r187975)
@@ -511,11 +511,10 @@ ar_parse_gnu_filename_table(struct archi
 		}
 	}
 	/*
-	 * Sanity check, last two chars must be `/\n' or '\n\n',
-	 * depending on whether the string table is padded by a '\n'
-	 * (string table produced by GNU ar always has a even size).
+	 * GNU ar always pads the table to an even size.
+	 * The pad character is either '\n' or '`'.
 	 */
-	if (p != ar->strtab + size && *p != '\n')
+	if (p != ar->strtab + size && *p != '\n' && *p != '`')
 		goto bad_string_table;
 
 	/* Enforce zero termination. */



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200902010233.n112X2fe040569>