tsan: fix darwin Go support
os_trace turns out to be a macro that creates static object. Function-static objects use __cxa_atexit and __dso_handle which are not present in Go runtime. llvm-svn: 267720
This commit is contained in:
parent
f875acbd77
commit
4592eb0534
|
@ -468,6 +468,7 @@ void LogMessageOnPrintf(const char *str) {
|
|||
}
|
||||
|
||||
void LogFullErrorReport(const char *buffer) {
|
||||
#ifndef SANITIZER_GO
|
||||
// Log with os_trace. This will make it into the crash log.
|
||||
#if SANITIZER_OS_TRACE
|
||||
if (GetMacosVersion() >= MACOS_VERSION_YOSEMITE) {
|
||||
|
@ -489,7 +490,6 @@ void LogFullErrorReport(const char *buffer) {
|
|||
}
|
||||
#endif
|
||||
|
||||
#ifndef SANITIZER_GO
|
||||
// Log to syslog.
|
||||
// The logging on OS X may call pthread_create so we need the threading
|
||||
// environment to be fully initialized. Also, this should never be called when
|
||||
|
@ -500,9 +500,9 @@ void LogFullErrorReport(const char *buffer) {
|
|||
BlockingMutexLock l(&syslog_lock);
|
||||
if (common_flags()->log_to_syslog)
|
||||
WriteToSyslog(buffer);
|
||||
#endif
|
||||
|
||||
// The report is added to CrashLog as part of logging all of Printf output.
|
||||
#endif
|
||||
}
|
||||
|
||||
SignalContext::WriteFlag SignalContext::GetWriteFlag(void *context) {
|
||||
|
|
Loading…
Reference in New Issue