Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 6 Dec 2008 06:02:27 +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: r185672 - head/lib/libarchive/test
Message-ID:  <200812060602.mB662RoX084707@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: kientzle
Date: Sat Dec  6 06:02:26 2008
New Revision: 185672
URL: http://svn.freebsd.org/changeset/base/185672

Log:
  Recover after test failure.

Modified:
  head/lib/libarchive/test/test_write_format_cpio.c

Modified: head/lib/libarchive/test/test_write_format_cpio.c
==============================================================================
--- head/lib/libarchive/test/test_write_format_cpio.c	Sat Dec  6 06:01:50 2008	(r185671)
+++ head/lib/libarchive/test/test_write_format_cpio.c	Sat Dec  6 06:02:26 2008	(r185672)
@@ -134,7 +134,10 @@ test_format(int	(*set_format)(struct arc
 	assertA(0 == archive_read_support_compression_all(a));
 	assertA(0 == archive_read_open_memory(a, buff, used));
 
-	assertEqualIntA(a, 0, archive_read_next_header(a, &ae));
+	if (!assertEqualIntA(a, 0, archive_read_next_header(a, &ae))) {
+		archive_read_finish(a);
+		return;
+	}
 
 	assertEqualInt(1, archive_entry_mtime(ae));
 	/* Not the same as above: cpio doesn't store hi-res times. */



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