From: Joel Rosdahl Date: Tue, 12 Jul 2016 20:44:37 +0000 (+0200) Subject: Don't use non-POSIX S_ISLNK macro X-Git-Tag: v3.3~73 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=b704f6e8be6761f455149b2a9a26192287953266;p=thirdparty%2Fccache.git Don't use non-POSIX S_ISLNK macro For portability. --- diff --git a/ccache.c b/ccache.c index b8147b580..4d0ffc3e9 100644 --- a/ccache.c +++ b/ccache.c @@ -2805,7 +2805,7 @@ cc_process_args(struct args *args, struct args **preprocessor_args, } lstat(argv[i], &st); - if (S_ISLNK(st.st_mode)) { + if ((st.st_mode & S_IFMT) == S_IFLNK) { /* Don't rewrite source file path if it's a symlink since make_relative_path resolves symlinks using realpath(3) and this leads to potentially choosing incorrect relative header files. See the