[all-commits] [llvm/llvm-project] 28800c: [sanitizer] Use consistent checks for XDR

Ian via All-commits all-commits at lists.llvm.org
Wed Jul 20 22:28:30 PDT 2022


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 28800c2e18972935cd4f942aa428c5e6cc4c1670
      https://github.com/llvm/llvm-project/commit/28800c2e18972935cd4f942aa428c5e6cc4c1670
  Author: Ian Anderson <iana at apple.com>
  Date:   2022-07-20 (Wed, 20 Jul 2022)

  Changed paths:
    M compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cpp

  Log Message:
  -----------
  [sanitizer] Use consistent checks for XDR

sanitizer_platform_limits_posix.h defines `__sanitizer_XDR ` if `SANITIZER_LINUX && !SANITIZER_ANDROID`, but sanitizer_platform_limits_posix.cpp tries to check it if `HAVE_RPC_XDR_H`. This coincidentally works because macOS has a broken <rpc/xdr.h> which causes `HAVE_RPC_XDR_H` to be 0, but if <rpc/xdr.h> is fixed then clang fails to compile on macOS. Restore the platform checks so that <rpc/xdr.h> can be fixed on macOS.

Reviewed By: vitalybuka

Differential Revision: https://reviews.llvm.org/D130060




More information about the All-commits mailing list