sanitizer_nolibc_test_main.cc revision cc8ed30ebfb4ff6f9d9c7e77760dd5c7841a1af8
1//===-- sanitizer_nolibc_test_main.cc -------------------------------------===//
2//
3//                     The LLVM Compiler Infrastructure
4//
5// This file is distributed under the University of Illinois Open Source
6// License. See LICENSE.TXT for details.
7//
8//===----------------------------------------------------------------------===//
9//
10// This file is a part of ThreadSanitizer/AddressSanitizer runtime.
11// Tests for libc independence of sanitizer_common.
12//
13//===----------------------------------------------------------------------===//
14
15#include "sanitizer_common/sanitizer_libc.h"
16
17// TODO(pcc): Remove these once the allocator dependency is gone.
18extern "C" void *__libc_malloc() { return 0; }
19extern "C" void __libc_free(void *p) {}
20
21extern "C" void _start() {
22  internal__exit(0);
23}
24