Title: [291150] trunk/Source/WebKit
Revision
291150
Author
dp...@igalia.com
Date
2022-03-11 01:20:28 -0800 (Fri, 11 Mar 2022)

Log Message

[GLIB] Debian Stable & Ubuntu LTS build is failing after r291093
https://bugs.webkit.org/show_bug.cgi?id=237756

Reviewed by Carlos Garcia Campos.

Use `soup_websocket_connection_send_message` when SOUP < 2.67.3.

* UIProcess/Inspector/glib/RemoteInspectorHTTPServer.cpp:

Modified Paths

Diff

Modified: trunk/Source/WebKit/ChangeLog (291149 => 291150)


--- trunk/Source/WebKit/ChangeLog	2022-03-11 08:40:16 UTC (rev 291149)
+++ trunk/Source/WebKit/ChangeLog	2022-03-11 09:20:28 UTC (rev 291150)
@@ -1,3 +1,14 @@
+2022-03-11  Diego Pino Garcia  <dp...@igalia.com>
+
+        [GLIB] Debian Stable & Ubuntu LTS build is failing after r291093
+        https://bugs.webkit.org/show_bug.cgi?id=237756
+
+        Reviewed by Carlos Garcia Campos.
+
+        Use `soup_websocket_connection_send_message` when SOUP < 2.67.3.
+
+        * UIProcess/Inspector/glib/RemoteInspectorHTTPServer.cpp:
+
 2022-03-11  Tim Horton  <timothy_hor...@apple.com>
 
         Disable WebGL and DOM GPU process when some dependencies are unavailable

Modified: trunk/Source/WebKit/UIProcess/Inspector/glib/RemoteInspectorHTTPServer.cpp (291149 => 291150)


--- trunk/Source/WebKit/UIProcess/Inspector/glib/RemoteInspectorHTTPServer.cpp	2022-03-11 08:40:16 UTC (rev 291149)
+++ trunk/Source/WebKit/UIProcess/Inspector/glib/RemoteInspectorHTTPServer.cpp	2022-03-11 09:20:28 UTC (rev 291150)
@@ -144,8 +144,12 @@
 
     auto utf8 = message.utf8();
     // Soup is going to copy the data immediately, so we can use g_bytes_new_static() here to avoid more data copies.
+#if SOUP_CHECK_VERSION(2, 67, 3)
     GRefPtr<GBytes> bytes = adoptGRef(g_bytes_new_static(utf8.data(), utf8.length()));
     soup_websocket_connection_send_message(webSocketConnection, SOUP_WEBSOCKET_DATA_TEXT, bytes.get());
+#else
+    soup_websocket_connection_send_text(webSocketConnection, CString(reinterpret_cast<const char*>(utf8.data()), utf8.length()).data());
+#endif
 }
 
 void RemoteInspectorHTTPServer::targetDidClose(uint64_t connectionID, uint64_t targetID)
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to