[PATCH] D22061: [sanitizer] Handle null in internal_sigaction_syscall

Derek Bruening via llvm-commits llvm-commits at lists.llvm.org
Wed Jul 6 13:20:58 PDT 2016


This revision was automatically updated to reflect the committed changes.
Closed by commit rL274665: [sanitizer] Handle null in internal_sigaction_syscall (authored by bruening).

Changed prior to commit:
  http://reviews.llvm.org/D22061?vs=62922&id=62952#toc

Repository:
  rL LLVM

http://reviews.llvm.org/D22061

Files:
  compiler-rt/trunk/lib/sanitizer_common/sanitizer_linux.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
@@ -673,6 +673,8 @@
 // We disable for Go simply because we have not yet added to buildgo.sh.
 #if defined(__x86_64__) && !SANITIZER_GO
 int internal_sigaction_syscall(int signum, const void *act, void *oldact) {
+  if (act == nullptr)
+    return internal_sigaction_norestorer(signum, act, oldact);
   __sanitizer_sigaction u_adjust;
   internal_memcpy(&u_adjust, act, sizeof(u_adjust));
 #if !SANITIZER_ANDROID || !SANITIZER_MIPS32


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D22061.62952.patch
Type: text/x-patch
Size: 691 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20160706/74bbd3d8/attachment.bin>


More information about the llvm-commits mailing list