PR c++/85815 - reference to member of enclosing template.
[official-gcc.git] / libsanitizer / sanitizer_common / sanitizer_common_nolibc.cc
blob7397a011098c4580699908ccdc6ecf1b44b57959
1 //===-- sanitizer_common_nolibc.cc ----------------------------------------===//
2 //
3 // This file is distributed under the University of Illinois Open Source
4 // License. See LICENSE.TXT for details.
5 //
6 //===----------------------------------------------------------------------===//
7 //
8 // This file contains stubs for libc function to facilitate optional use of
9 // libc in no-libcdep sources.
10 //===----------------------------------------------------------------------===//
12 #include "sanitizer_platform.h"
13 #include "sanitizer_common.h"
14 #include "sanitizer_libc.h"
16 namespace __sanitizer {
18 // The Windows implementations of these functions use the win32 API directly,
19 // bypassing libc.
20 #if !SANITIZER_WINDOWS
21 #if SANITIZER_LINUX
22 bool ShouldLogAfterPrintf() { return false; }
23 void LogMessageOnPrintf(const char *str) {}
24 #endif
25 void WriteToSyslog(const char *buffer) {}
26 void Abort() { internal__exit(1); }
27 void SleepForSeconds(int seconds) { internal_sleep(seconds); }
28 #endif // !SANITIZER_WINDOWS
30 #if !SANITIZER_WINDOWS && !SANITIZER_MAC
31 void ListOfModules::init() {}
32 #endif
34 } // namespace __sanitizer