Skip to content
Permalink
Browse files
REGRESSION(r291038) [GTK][WPE] Fix build without remote inspector
https://bugs.webkit.org/show_bug.cgi?id=240305

Patch by Olivier Blin <olivier.blin@softathome.com> on 2022-05-12
Reviewed by Michael Catanzaro.

* Shared/WebProcessCreationParameters.cpp:
(WebKit::WebProcessCreationParameters::encode const):
(WebKit::WebProcessCreationParameters::decode):
* Shared/WebProcessCreationParameters.h:
* UIProcess/glib/WebProcessPoolGLib.cpp:
(WebKit::WebProcessPool::platformInitializeWebProcess):
* WebProcess/glib/WebProcessGLib.cpp:
(WebKit::WebProcess::platformInitializeWebProcess):

Canonical link: https://commits.webkit.org/250488@main
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@294103 268f45cc-cd09-0410-ab3c-d52691b4dbfc
  • Loading branch information
blino authored and webkit-commit-queue committed May 12, 2022
1 parent f4fdc50 commit 0d5437dbaa7bdb52f60b64bc7dd5a39adee14e81
Showing 5 changed files with 33 additions and 1 deletion.
@@ -1,3 +1,19 @@
2022-05-12 Olivier Blin <olivier.blin@softathome.com>

REGRESSION(r291038) [GTK][WPE] Fix build without remote inspector
https://bugs.webkit.org/show_bug.cgi?id=240305

Reviewed by Michael Catanzaro.

* Shared/WebProcessCreationParameters.cpp:
(WebKit::WebProcessCreationParameters::encode const):
(WebKit::WebProcessCreationParameters::decode):
* Shared/WebProcessCreationParameters.h:
* UIProcess/glib/WebProcessPoolGLib.cpp:
(WebKit::WebProcessPool::platformInitializeWebProcess):
* WebProcess/glib/WebProcessGLib.cpp:
(WebKit::WebProcess::platformInitializeWebProcess):

2022-05-12 Yousuke Kimoto <yousuke.kimoto@sony.com>

[WinCairo] Fix a compile error due to InspectorResourceURLSchemeHandler
@@ -208,8 +208,10 @@ void WebProcessCreationParameters::encode(IPC::Encoder& encoder) const
#if USE(GLIB)
encoder << applicationID;
encoder << applicationName;
#if ENABLE(REMOTE_INSPECTOR)
encoder << inspectorServerAddress;
#endif
#endif

#if USE(ATSPI)
encoder << accessibilityBusAddress;
@@ -558,12 +560,14 @@ bool WebProcessCreationParameters::decode(IPC::Decoder& decoder, WebProcessCreat
if (!decoder.decode(parameters.applicationName))
return false;

#if ENABLE(REMOTE_INSPECTOR)
std::optional<CString> inspectorServerAddress;
decoder >> inspectorServerAddress;
if (!inspectorServerAddress)
return false;
parameters.inspectorServerAddress = WTFMove(*inspectorServerAddress);
#endif
#endif

#if USE(ATSPI)
std::optional<String> accessibilityBusAddress;
@@ -249,8 +249,10 @@ struct WebProcessCreationParameters {
#if USE(GLIB)
String applicationID;
String applicationName;
#if ENABLE(REMOTE_INSPECTOR)
CString inspectorServerAddress;
#endif
#endif

#if USE(ATSPI)
String accessibilityBusAddress;
@@ -32,10 +32,13 @@
#include "MemoryPressureMonitor.h"
#include "WebMemoryPressureHandler.h"
#include "WebProcessCreationParameters.h"
#include <JavaScriptCore/RemoteInspector.h>
#include <WebCore/PlatformDisplay.h>
#include <wtf/FileSystem.h>

#if ENABLE(REMOTE_INSPECTOR)
#include <JavaScriptCore/RemoteInspector.h>
#endif

#if USE(GSTREAMER)
#include <WebCore/GStreamerCommon.h>
#endif
@@ -119,7 +122,9 @@ void WebProcessPool::platformInitializeWebProcess(const WebProcessProxy& process
parameters.applicationID = String::fromLatin1(g_application_get_application_id(app));
parameters.applicationName = String::fromLatin1(g_get_application_name());

#if ENABLE(REMOTE_INSPECTOR)
parameters.inspectorServerAddress = Inspector::RemoteInspector::inspectorServerAddress();
#endif

#if USE(ATSPI)
static const char* accessibilityBusAddress = getenv("WEBKIT_A11Y_BUS_ADDRESS");
@@ -31,7 +31,10 @@
#include "WebKitWebExtensionPrivate.h"
#include "WebPage.h"
#include "WebProcessCreationParameters.h"

#if ENABLE(REMOTE_INSPECTOR)
#include <JavaScriptCore/RemoteInspector.h>
#endif

#if USE(GSTREAMER)
#include <WebCore/GStreamerCommon.h>
@@ -153,8 +156,10 @@ void WebProcess::platformInitializeWebProcess(WebProcessCreationParameters& para
if (!parameters.applicationName.isEmpty())
WebCore::setApplicationName(parameters.applicationName);

#if ENABLE(REMOTE_INSPECTOR)
if (!parameters.inspectorServerAddress.isNull())
Inspector::RemoteInspector::setInspectorServerAddress(WTFMove(parameters.inspectorServerAddress));
#endif

#if USE(ATSPI)
AccessibilityAtspi::singleton().connect(parameters.accessibilityBusAddress);

0 comments on commit 0d5437d

Please sign in to comment.