[PATCH] D58413: [sanitizers] Restore internal_readlink for x32

Phabricator via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Feb 20 03:43:31 PST 2019


This revision was automatically updated to reflect the committed changes.
Closed by commit rL354451: [sanitizers] Restore internal_readlink for x32 (authored by hjl, committed by ).
Herald added subscribers: jdoerfert, delcypher.

Changed prior to commit:
  https://reviews.llvm.org/D58413?vs=187481&id=187545#toc

Repository:
  rL LLVM

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D58413/new/

https://reviews.llvm.org/D58413

Files:
  compiler-rt/trunk/lib/sanitizer_common/sanitizer_linux.cc
  compiler-rt/trunk/lib/sanitizer_common/tests/sanitizer_common_test.cc


Index: compiler-rt/trunk/lib/sanitizer_common/sanitizer_linux.cc
===================================================================
--- compiler-rt/trunk/lib/sanitizer_common/sanitizer_linux.cc
+++ compiler-rt/trunk/lib/sanitizer_common/sanitizer_linux.cc
@@ -400,7 +400,7 @@
   return internal_syscall(SYSCALL(readlinkat), AT_FDCWD, (uptr)path, (uptr)buf,
                           bufsize);
 #else
-  return internal_syscall(SYSCALL(readlink), path, buf, bufsize);
+  return internal_syscall(SYSCALL(readlink), (uptr)path, (uptr)buf, bufsize);
 #endif
 }
 
Index: compiler-rt/trunk/lib/sanitizer_common/tests/sanitizer_common_test.cc
===================================================================
--- compiler-rt/trunk/lib/sanitizer_common/tests/sanitizer_common_test.cc
+++ compiler-rt/trunk/lib/sanitizer_common/tests/sanitizer_common_test.cc
@@ -438,4 +438,9 @@
   EXPECT_DEATH(address_range.Unmap(base_addr + (PageSize * 2), PageSize), ".*");
 }
 
+TEST(SanitizerCommon, ReadBinaryNameCached) {
+  char buf[256];
+  EXPECT_NE((uptr)0, ReadBinaryNameCached(buf, sizeof(buf)));
+}
+
 }  // namespace __sanitizer


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D58413.187545.patch
Type: text/x-patch
Size: 1123 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20190220/feff3d10/attachment.bin>


More information about the llvm-commits mailing list