[asan] Fix Android build for API >= 21.

/code/llvm/projects/compiler-rt/lib/sanitizer_common/sanitizer_linux.cc:971:8: error: address of function 'dl_iterate_phdr' will always evaluate to 'true' [-Werror,-Wpointer-bool-conversion]
  if (!dl_iterate_phdr)
      ~^~~~~~~~~~~~~~~
/code/llvm/projects/compiler-rt/lib/sanitizer_common/sanitizer_linux.cc:971:8: note: prefix with the address-of operator to silence this warning
  if (!dl_iterate_phdr)
       ^
       &

llvm-svn: 239321
This commit is contained in:
Evgeniy Stepanov 2015-06-08 18:15:52 +00:00
parent 572cd900b2
commit e33f64f682
1 changed files with 1 additions and 1 deletions

View File

@ -968,7 +968,7 @@ static int dl_iterate_phdr_test_cb(struct dl_phdr_info *info, size_t size,
static atomic_uint32_t android_api_level;
static u32 AndroidDetectApiLevel() {
if (!dl_iterate_phdr)
if (!&dl_iterate_phdr)
return 19; // K or lower
bool base_name_seen = false;
dl_iterate_phdr(dl_iterate_phdr_test_cb, &base_name_seen);