force-single-process
authorAlberto Garcia <berto@igalia.com>
Tue, 12 Nov 2019 12:15:29 +0000 (12:15 +0000)
committerAlberto Garcia <berto@igalia.com>
Tue, 12 Nov 2019 12:15:29 +0000 (12:15 +0000)
===================================================================

Gbp-Pq: Name force-single-process.patch

Source/WebKit/UIProcess/API/glib/WebKitWebContext.cpp

index ae9e61383f87db87117ae30c993be1230cd2a1b3..9f06a9752d60e3b8fe9152b336d0c9b1d9fb80d8 100644 (file)
@@ -348,8 +348,16 @@ ALLOW_DEPRECATED_DECLARATIONS_END
         configuration.setLocalStorageDirectory(FileSystem::stringFromFileSystemRepresentation(priv->localStorageDirectory.data()));
 
     const char* useSingleWebProcess = getenv("WEBKIT_USE_SINGLE_WEB_PROCESS");
-    if (useSingleWebProcess && strcmp(useSingleWebProcess, "0"))
-        configuration.setUsesSingleWebProcess(true);
+    if (useSingleWebProcess) {
+        if (strcmp(useSingleWebProcess, "0")) {
+            configuration.setUsesSingleWebProcess(true);
+        }
+    } else {
+        const char* prgname = g_get_prgname();
+        if (!g_strcmp0(prgname, "evolution") || !g_strcmp0(prgname, "geary")) {
+            configuration.setUsesSingleWebProcess(true);
+        }
+    }
     priv->processPool = WebProcessPool::create(configuration);
 
     if (!priv->websiteDataManager)