]> git.ipfire.org Git - thirdparty/libarchive.git/commitdiff
On Windows, pass test_passthrough_dotdot in bsdcpio_test.
authorMichihiro NAKAJIMA <ggcueroad@gmail.com>
Fri, 13 Mar 2009 13:42:22 +0000 (09:42 -0400)
committerMichihiro NAKAJIMA <ggcueroad@gmail.com>
Fri, 13 Mar 2009 13:42:22 +0000 (09:42 -0400)
SVN-Revision: 770

cpio/test/test_passthrough_dotdot.c

index 5217ada2aa639fcbac1b4aa74d489cb886d3ad1c..8ebc4f91405c6f50a6054ef0f8a12396c43c5b3e 100644 (file)
@@ -71,7 +71,7 @@ DEFINE_TEST(test_passthrough_dotdot)
        assertEqualInt(0, chdir(".."));
 
        /* Verify stderr and stdout. */
-       assertFileContents("../.\n../file\n1 block\n", 21, "stderr");
+       assertTextFileContents("../.\n../file\n1 block\n", "stderr");
        assertEmptyFile("stdout");
 
        /* Regular file. */
@@ -80,7 +80,11 @@ DEFINE_TEST(test_passthrough_dotdot)
        assertEqualInt(r, 0);
        if (r == 0) {
                assert(S_ISREG(st.st_mode));
+#ifdef _WIN32
+               assertEqualInt(0600, st.st_mode & 0700);
+#else
                assertEqualInt(0642, st.st_mode & 0777);
+#endif
                assertEqualInt(10, st.st_size);
                assertEqualInt(1, st.st_nlink);
        }