From: Jakub Jelinek Date: Fri, 21 Nov 2014 14:03:37 +0000 (+0100) Subject: re PR sanitizer/64013 (libsanitizer fails to build) X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=7697b16f45c592826e6a6a1a3ac2ca7f6db530bc;p=gcc.git re PR sanitizer/64013 (libsanitizer fails to build) PR sanitizer/64013 * sanitizer_common/sanitizer_linux.cc (FileExists): Cherry pick upstream r222532. From-SVN: r217921 --- diff --git a/libsanitizer/ChangeLog b/libsanitizer/ChangeLog index e3aab56e00b..ed32d032d8e 100644 --- a/libsanitizer/ChangeLog +++ b/libsanitizer/ChangeLog @@ -1,3 +1,9 @@ +2014-11-21 Jakub Jelinek + + PR target/61137 + * config/ia64/ia64.c (ia64_attribute_takes_identifier_p): New function. + (TARGET_ATTRIBUTE_TAKES_IDENTIFIER_P): Redefine to it. + 2014-11-14 Uros Bizjak * sanitizer_common/Makefile.am (AM_CXXFLAGS): Use -std=gnu++11. diff --git a/libsanitizer/sanitizer_common/sanitizer_linux.cc b/libsanitizer/sanitizer_common/sanitizer_linux.cc index 8c7979fc6b5..9feb307db9f 100644 --- a/libsanitizer/sanitizer_common/sanitizer_linux.cc +++ b/libsanitizer/sanitizer_common/sanitizer_linux.cc @@ -281,17 +281,15 @@ uptr internal_execve(const char *filename, char *const argv[], // ----------------- sanitizer_common.h bool FileExists(const char *filename) { -#if SANITIZER_USES_CANONICAL_LINUX_SYSCALLS struct stat st; +#if SANITIZER_USES_CANONICAL_LINUX_SYSCALLS if (internal_syscall(SYSCALL(newfstatat), AT_FDCWD, filename, &st, 0)) - return false; #else - struct stat st; if (internal_stat(filename, &st)) +#endif return false; // Sanity check: filename is a regular file. return S_ISREG(st.st_mode); -#endif } uptr GetTid() {