opnsense-ports/devel/electron32/files/patch-base_debug_stack__trace.cc
Franco Fichtner fd3bf1794a */*: sync with upstream
Taken from: FreeBSD
2024-09-23 09:02:17 +02:00

29 lines
1.2 KiB
C++

--- base/debug/stack_trace.cc.orig 2024-08-14 20:54:23 UTC
+++ base/debug/stack_trace.cc
@@ -255,7 +255,7 @@ bool StackTrace::WillSymbolizeToStreamForTesting() {
// Symbols are not expected to be reliable when gn args specifies
// symbol_level=0.
return false;
-#elif defined(__UCLIBC__) || defined(_AIX)
+#elif defined(__UCLIBC__) || defined(_AIX) || BUILDFLAG(IS_BSD)
// StackTrace::OutputToStream() is not implemented under uclibc, nor AIX.
// See https://crbug.com/706728
return false;
@@ -317,7 +317,7 @@ std::string StackTrace::ToStringWithPrefix(cstring_vie
std::string StackTrace::ToStringWithPrefix(cstring_view prefix_string) const {
std::stringstream stream;
-#if !defined(__UCLIBC__) && !defined(_AIX)
+#if !defined(__UCLIBC__) && !defined(_AIX) && !BUILDFLAG(IS_BSD)
OutputToStreamWithPrefix(&stream, prefix_string);
#endif
return stream.str();
@@ -341,7 +341,7 @@ std::ostream& operator<<(std::ostream& os, const Stack
}
std::ostream& operator<<(std::ostream& os, const StackTrace& s) {
-#if !defined(__UCLIBC__) && !defined(_AIX)
+#if !defined(__UCLIBC__) && !defined(_AIX) && !BUILDFLAG(IS_BSD)
s.OutputToStream(&os);
#else
os << "StackTrace::OutputToStream not implemented.";