summaryrefslogtreecommitdiff
path: root/www/chromium/files/patch-chrome_common_profiler_thread__profiler.cc
diff options
context:
space:
mode:
Diffstat (limited to 'www/chromium/files/patch-chrome_common_profiler_thread__profiler.cc')
-rw-r--r--www/chromium/files/patch-chrome_common_profiler_thread__profiler.cc20
1 files changed, 20 insertions, 0 deletions
diff --git a/www/chromium/files/patch-chrome_common_profiler_thread__profiler.cc b/www/chromium/files/patch-chrome_common_profiler_thread__profiler.cc
new file mode 100644
index 000000000000..47725ace7955
--- /dev/null
+++ b/www/chromium/files/patch-chrome_common_profiler_thread__profiler.cc
@@ -0,0 +1,20 @@
+--- chrome/common/profiler/thread_profiler.cc.orig 2021-04-23 13:14:22 UTC
++++ chrome/common/profiler/thread_profiler.cc
+@@ -58,6 +58,9 @@ ThreadProfiler* g_main_thread_instance = nullptr;
+ constexpr double kFractionOfExecutionTimeToSample = 0.02;
+
+ bool IsCurrentProcessBackgrounded() {
++#if defined(OS_BSD)
++ return false;
++#else
+ #if defined(OS_MAC)
+ // Port provider that returns the calling process's task port, ignoring its
+ // argument.
+@@ -71,6 +74,7 @@ bool IsCurrentProcessBackgrounded() {
+ #else // defined(OS_MAC)
+ return base::Process::Current().IsProcessBackgrounded();
+ #endif // defined(OS_MAC)
++#endif
+ }
+
+ #if defined(OS_ANDROID) && BUILDFLAG(ENABLE_ARM_CFI_TABLE)