diff options
Diffstat (limited to 'community/chromium/no-execinfo.patch')
-rw-r--r-- | community/chromium/no-execinfo.patch | 75 |
1 files changed, 35 insertions, 40 deletions
diff --git a/community/chromium/no-execinfo.patch b/community/chromium/no-execinfo.patch index c91fbd7c64..95451f256b 100644 --- a/community/chromium/no-execinfo.patch +++ b/community/chromium/no-execinfo.patch @@ -1,82 +1,77 @@ -diff --git a/base/debug/stack_trace_posix.cc b/base/debug/stack_trace_posix.cc -index 7696be8..20ebe67 100644 ---- a/base/debug/stack_trace_posix.cc -+++ base/debug/stack_trace_posix.cc +--- base/debug/stack_trace_posix.cc.orig 2017-07-27 14:05:05.534241443 +0000 ++++ base/debug/stack_trace_posix.cc 2017-07-27 14:07:54.669231362 +0000 @@ -26,7 +26,7 @@ #if !defined(USE_SYMBOLIZE) #include <cxxabi.h> #endif -#if !defined(__UCLIBC__) && !defined(_AIX) -+#if defined(__GLIBC__) ++#if defined(__GLIBC__) && !defined(_AIX) #include <execinfo.h> #endif -@@ -82,7 +82,7 @@ void DemangleSymbols(std::string* text) { +@@ -80,7 +80,7 @@ // Note: code in this function is NOT async-signal safe (std::string uses // malloc internally). -#if !defined(__UCLIBC__) && !defined(_AIX) -+#if defined(__GLIBC__) ++#if defined(__GLIBC__) && !defined(_AIX) std::string::size_type search_from = 0; while (search_from < text->size()) { // Look for the start of a mangled symbol, from search_from. -@@ -129,7 +129,7 @@ class BacktraceOutputHandler { +@@ -115,7 +115,7 @@ + search_from = mangled_start + 2; + } + } +-#endif // !defined(__UCLIBC__) && !defined(_AIX) ++#endif // defined(__GLIBC__) && !defined(_AIX) + } + #endif // !defined(USE_SYMBOLIZE) + +@@ -127,7 +127,7 @@ virtual ~BacktraceOutputHandler() {} }; -#if !defined(__UCLIBC__) && !defined(_AIX) -+#if defined(__GLIBC__) ++#if defined(__GLIBC__) && !defined(_AIX) void OutputPointer(void* pointer, BacktraceOutputHandler* handler) { // This should be more than enough to store a 64-bit number in hex: // 16 hex digits + 1 for null-terminator. -@@ -705,6 +705,10 @@ class SandboxSymbolizeHelper { - } // namespace - - bool EnableInProcessStackDumping() { -+#if defined(OS_LINUX) && !defined(__GLIBC__) -+// let system handler deal with the dumps -+ return true; -+#else - #if defined(USE_SYMBOLIZE) - SandboxSymbolizeHelper::GetInstance(); - #endif // USE_SYMBOLIZE -@@ -738,6 +742,7 @@ bool EnableInProcessStackDumping() { - #endif // !defined(OS_LINUX) - - return success; -+#endif +@@ -204,7 +204,7 @@ + } + #endif // defined(USE_SYMBOLIZE) } +-#endif // !defined(__UCLIBC__) && !defined(_AIX) ++#endif // defined(__GLIBC__) && !defined(_AIX) - void SetStackDumpFirstChanceCallback(bool (*handler)(int, void*, void*)) { -@@ -749,7 +754,7 @@ StackTrace::StackTrace(size_t count) { + void PrintToStderr(const char* output) { + // NOTE: This code MUST be async-signal safe (it's used by in-process +@@ -721,7 +721,7 @@ // NOTE: This code MUST be async-signal safe (it's used by in-process // stack dumping signal handler). NO malloc or stdio is allowed here. -#if !defined(__UCLIBC__) && !defined(_AIX) -+#if defined(__GLIBC__) ++#if defined(__GLIBC__) && !defined(_AIX) count = std::min(arraysize(trace_), count); // Though the backtrace API man page does not list any possible negative -@@ -764,13 +769,13 @@ void StackTrace::Print() const { - // NOTE: This code MUST be async-signal safe (it's used by in-process - // stack dumping signal handler). NO malloc or stdio is allowed here. +@@ -827,13 +827,13 @@ + // NOTE: This code MUST be async-signal safe (it's used by in-process + // stack dumping signal handler). NO malloc or stdio is allowed here. -#if !defined(__UCLIBC__) && !defined(_AIX) -+#if defined(__GLIBC__) ++#if defined(__GLIBC__) && !defined(_AIX) PrintBacktraceOutputHandler handler; - ProcessBacktrace(trace_, count_, &handler); + ProcessBacktrace(trace_, count_, prefix_string, &handler); #endif } -#if !defined(__UCLIBC__) && !defined(_AIX) -+#if defined(__GLIBC__) - void StackTrace::OutputToStream(std::ostream* os) const { ++#if defined(__GLIBC__) && !defined(_AIX) + void StackTrace::OutputToStreamWithPrefix(std::ostream* os, + const char* prefix_string) const { StreamBacktraceOutputHandler handler(os); - ProcessBacktrace(trace_, count_, &handler); -diff --git a/third_party/WebKit/Source/platform/wtf/Assertions.cpp b/third_party/WebKit/Source/platform/wtf/Assertions.cpp -index 9bdece7..0c76188 100644 ---- ./third_party/blink/renderer/platform/wtf/assertions.cc -+++ ./third_party/blink/renderer/platform/wtf/assertions.cc +--- third_party/blink/renderer/platform/wtf/assertions.cc.orig 2017-09-11 12:27:06.948854813 +0000 ++++ third_party/blink/renderer/platform/wtf/assertions.cc 2017-09-11 12:29:34.639862433 +0000 @@ -56,7 +56,7 @@ #include <windows.h> #endif |