[PATCH] D12117: Replace __asan_set_error_exit_code() with __sanitizer_set_death_callback()

Alexey Samsonov via cfe-commits cfe-commits at lists.llvm.org
Wed Aug 19 10:29:07 PDT 2015


This revision was automatically updated to reflect the committed changes.
Closed by commit rL245467: Replace __asan_set_error_exit_code() with __sanitizer_set_death_callback() (authored by samsonov).

Changed prior to commit:
  http://reviews.llvm.org/D12117?vs=32456&id=32572#toc

Repository:
  rL LLVM

http://reviews.llvm.org/D12117

Files:
  libcxx/trunk/test/libcxx/containers/sequences/vector/asan.pass.cpp

Index: libcxx/trunk/test/libcxx/containers/sequences/vector/asan.pass.cpp
===================================================================
--- libcxx/trunk/test/libcxx/containers/sequences/vector/asan.pass.cpp
+++ libcxx/trunk/test/libcxx/containers/sequences/vector/asan.pass.cpp
@@ -7,6 +7,8 @@
 //
 //===----------------------------------------------------------------------===//
 
+// UNSUPPORTED: clang-3.3, clang-3.4, clang-3.5
+
 // <vector>
 
 // reference operator[](size_type n);
@@ -21,8 +23,11 @@
 #include "test_macros.h"
 
 #ifndef _LIBCPP_HAS_NO_ASAN
-extern "C" void __asan_set_error_exit_code(int);
+extern "C" void __sanitizer_set_death_callback(void (*callback)(void));
 
+void do_exit() {
+  exit(0);
+}
 
 int main()
 {
@@ -48,7 +53,7 @@
         assert(is_contiguous_container_asan_correct(v));
     }
 
-    __asan_set_error_exit_code(0);
+    __sanitizer_set_death_callback(do_exit);
     {
         typedef int T;
         typedef std::vector<T> C;


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D12117.32572.patch
Type: text/x-patch
Size: 977 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20150819/07a69f13/attachment-0001.bin>


More information about the cfe-commits mailing list