Skip to content

Commit

Permalink
Fix bug in FF132 that causes MacOS builds to fail
Browse files Browse the repository at this point in the history
Without --enable-backgroundtasks, macOS fails seem to fail after this change:
https://phabricator.services.mozilla.com/D219834

This commit patches the broken code in nsAppRunner.
  • Loading branch information
daijro committed Nov 2, 2024
1 parent b5b00d6 commit 00f1267
Showing 1 changed file with 21 additions and 0 deletions.
21 changes: 21 additions & 0 deletions patches/backgroudtasks-bugfix.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
diff --git a/toolkit/xre/nsAppRunner.cpp b/toolkit/xre/nsAppRunner.cpp
index 318ee7e293..8430bb4e82 100644
--- a/toolkit/xre/nsAppRunner.cpp
+++ b/toolkit/xre/nsAppRunner.cpp
@@ -5640,10 +5640,14 @@ nsresult XREMain::XRE_mainRun() {

if (!AppShutdown::IsInOrBeyond(ShutdownPhase::AppShutdownConfirmed)) {
#ifdef XP_MACOSX
- if (!BackgroundTasks::IsBackgroundTaskMode()) {
+#ifdef MOZ_BACKGROUNDTASKS
+ if (!BackgroundTasks::IsBackgroundTaskMode()) {
+#endif
rv = appStartup->CreateHiddenWindow();
NS_ENSURE_SUCCESS(rv, NS_ERROR_FAILURE);
- }
+#ifdef MOZ_BACKGROUNDTASKS
+ }
+#endif
#endif

#ifdef XP_WIN

0 comments on commit 00f1267

Please sign in to comment.