From: Ignacio Casal Quinteiro Date: Thu, 8 Sep 2016 12:53:18 +0000 (+0200) Subject: test_write_format_gnutar_filenames: use AE_IFLNK instead of S_IFLNK X-Git-Tag: v3.2.2~14^2~1^2 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=302dcbca54412b6340d3bb4abb95e76f4553cde3;p=thirdparty%2Flibarchive.git test_write_format_gnutar_filenames: use AE_IFLNK instead of S_IFLNK Since S_IFLNK will fail on windows. https://github.com/libarchive/libarchive/issues/769 --- diff --git a/libarchive/test/test_write_format_gnutar_filenames.c b/libarchive/test/test_write_format_gnutar_filenames.c index 26457d357..655e998ed 100644 --- a/libarchive/test/test_write_format_gnutar_filenames.c +++ b/libarchive/test/test_write_format_gnutar_filenames.c @@ -100,6 +100,10 @@ DEFINE_TEST(test_write_format_gnutar_linknames) size_t used; int i; +#ifdef S_IFLNK + assertEqualInt(S_IFLNK, AE_IFLNK); +#endif + buff = malloc(buffsize); /* million bytes of work area */ assert(buff != NULL); @@ -109,7 +113,7 @@ DEFINE_TEST(test_write_format_gnutar_linknames) archive_entry_set_birthtime(template, 3, 30); archive_entry_set_ctime(template, 4, 40); archive_entry_set_mtime(template, 5, 50); - archive_entry_set_mode(template, S_IFLNK | 0755); + archive_entry_set_mode(template, AE_IFLNK | 0755); archive_entry_copy_pathname(template, "link"); for (i = 0; i < 2000; ++i) {