[Webkit-unassigned] [Bug 199151] [SOUP] Use libsoup WebSockets API

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Thu Jun 27 01:09:54 PDT 2019


https://bugs.webkit.org/show_bug.cgi?id=199151

--- Comment #13 from Carlos Garcia Campos <cgarcia at igalia.com> ---
Comment on attachment 372916
  --> https://bugs.webkit.org/attachment.cgi?id=372916
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=372916&action=review

>> Source/WebKit/NetworkProcess/soup/WebSocketTaskSoup.h:38
>> +class WebSocketTask {
> 
> Some small code is shared between the soup and cocoa versions.
> Maybe code should be shared.

Yes, we could move to a shared header instead of the current one just including the platform ones.

>> Source/WebKit/WebProcess/Network/WebSocketChannel.cpp:164
>> +void WebSocketChannel::didConnect(const String& subprotocol)
> 
> String&&

I'm following what other IPC message chandlers do. I think we should change the others too, so better to do it in a follow up. I'll submit a new patch.

>> Source/WebKit/WebProcess/Network/WebSocketChannel.cpp:249
>> +    // FIXME: do something with reason.
> 
> reason might not be a great name since it relates to didClose.
> Maybe errorMessage might be better.
> 
> There is a preexisting issue as well in the sense we might usually need to call didClose after didFail to trigger the onclose event.
> This is not really consistent with other code where didFail is final.
> Maybe we should rename didFail to didReceiveMessageError.

It's the same nomenclature used in WebCore/Modules/websockets/WebSocketChannel.cpp. In the old code WebSocketChannel::fail() calls m_handle->disconnect() after m_client->didReceiveMessageError() which closes the socket stream causing the close.

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-unassigned/attachments/20190627/91184782/attachment-0001.html>


More information about the webkit-unassigned mailing list