File tree Expand file tree Collapse file tree 2 files changed +12
-0
lines changed Expand file tree Collapse file tree 2 files changed +12
-0
lines changed Original file line number Diff line number Diff line change 35
35
#include " GeckoProfiler.h"
36
36
#include " nsAppRunner.h"
37
37
#include " xpcpublic.h"
38
+ #ifdef MOZ_BACKGROUNDTASKS
39
+ # include " mozilla/BackgroundTasks.h"
40
+ #endif
38
41
39
42
#if defined(XP_WIN)
40
43
# include < windows.h>
@@ -115,6 +118,12 @@ StartupCache* StartupCache::GetSingletonNoInit() {
115
118
}
116
119
117
120
StartupCache* StartupCache::GetSingleton () {
121
+ #ifdef MOZ_BACKGROUNDTASKS
122
+ if (BackgroundTasks::IsBackgroundTaskMode ()) {
123
+ return nullptr ;
124
+ }
125
+ #endif
126
+
118
127
if (!gStartupCache ) {
119
128
if (!XRE_IsParentProcess ()) {
120
129
return nullptr ;
Original file line number Diff line number Diff line change @@ -31,4 +31,7 @@ XPIDL_SOURCES += [
31
31
"nsIStartupCacheInfo.idl" ,
32
32
]
33
33
34
+ if CONFIG ["MOZ_BACKGROUNDTASKS" ]:
35
+ DEFINES ["MOZ_BACKGROUNDTASKS" ] = True
36
+
34
37
FINAL_LIBRARY = "xul"
You can’t perform that action at this time.
0 commit comments