From: Michihiro NAKAJIMA Date: Mon, 23 Feb 2009 13:19:34 +0000 (-0500) Subject: Tweak a mtree format test. X-Git-Tag: v2.7.0~218 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=6cf83ca0343c85f7099d926d06e7d7e457211bc7;p=thirdparty%2Flibarchive.git Tweak a mtree format test. Make directories for through the routine which open a directory in reading a mtree format. If we don't make directories, the routine won't try to open the directory. SVN-Revision: 707 --- diff --git a/libarchive/test/test_read_format_mtree.c b/libarchive/test/test_read_format_mtree.c index ef34af8f7..ad1b5ac6d 100644 --- a/libarchive/test/test_read_format_mtree.c +++ b/libarchive/test/test_read_format_mtree.c @@ -52,6 +52,15 @@ DEFINE_TEST(test_read_format_mtree) struct archive_entry *ae; struct archive *a; + /* + * An access error occurred on some platform when mtree + * format handling open a directory. It is for through + * the routine which open a directory that we create + * "dir" and "dir2" directories. + */ + assertEqualInt(0, mkdir("dir", 0775)); + assertEqualInt(0, mkdir("dir2", 0775)); + assert((a = archive_read_new()) != NULL); assertEqualIntA(a, ARCHIVE_OK, archive_read_support_compression_all(a));