[PATCH] Add FreeBSD support to the address sanitizer's assign_large_valloc_to_global.cc test case

Viktor Kutuzov vkutuzov at accesssoftek.com
Wed Jul 16 03:22:48 PDT 2014


Closed by commit rL213135 (authored by vkutuzov).

REPOSITORY
  rL LLVM

http://reviews.llvm.org/D4525

Files:
  compiler-rt/trunk/test/asan/TestCases/Posix/assign_large_valloc_to_global.cc

Index: compiler-rt/trunk/test/asan/TestCases/Posix/assign_large_valloc_to_global.cc
===================================================================
--- compiler-rt/trunk/test/asan/TestCases/Posix/assign_large_valloc_to_global.cc
+++ compiler-rt/trunk/test/asan/TestCases/Posix/assign_large_valloc_to_global.cc
@@ -1,8 +1,9 @@
 // Make sure we don't report a leak nor hang.
 // RUN: %clangxx_asan -O3 %s -o %t && %run %t
 #include <stdlib.h>
-#ifndef __APPLE__
+#include <unistd.h>
+#if !defined(__APPLE__) && !defined(__FreeBSD__)
 # include <malloc.h>
-#endif  // __APPLE__
+#endif  // !__APPLE__ && !__FreeBSD__
 int *p = (int*)valloc(1 << 20);
 int main() { }
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D4525.11494.patch
Type: text/x-patch
Size: 667 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20140716/82da23fe/attachment.bin>


More information about the llvm-commits mailing list