]> git.ipfire.org Git - thirdparty/libarchive.git/commitdiff
Fix builid failure on FreeBSD 10.
authorMichihiro NAKAJIMA <ggcueroad@gmail.com>
Sun, 29 Jun 2014 08:16:20 +0000 (17:16 +0900)
committerMichihiro NAKAJIMA <ggcueroad@gmail.com>
Sun, 29 Jun 2014 08:16:20 +0000 (17:16 +0900)
On FreeBSD 10, ENOTSUP and EOPNOTSUPP are the same value,
so it cannot be used in the same switch statement.

libarchive/archive_write_disk_posix.c

index 426e2428714e9fb192c9277f5b5c5da39e7d0903..87f4f0e56a65f725a24d24b978fdcecce7708166 100644 (file)
@@ -3063,7 +3063,9 @@ set_mode(struct archive_write_disk *a, int mode)
                        switch (errno) {
                        case ENOTSUP:
                        case ENOSYS:
+#if ENOTSUP != EOPNOTSUPP
                        case EOPNOTSUPP:
+#endif
                                /*
                                 * if lchmod is defined but the platform
                                 * doesn't support it, silently ignore