Bug 207794

Summary: Add WebInspector support to WebKit::WebSocketChannel
Product: WebKit Reporter: youenn fablet <youennf>
Component: WebCore Misc.Assignee: youenn fablet <youennf>
Status: RESOLVED FIXED    
Severity: Normal CC: achristensen, annulen, commit-queue, d3sk41, darin, ews-watchlist, gyuyoung.kim, ryuan.choi, sergio, toyoshim, webkit-bug-importer, yutak
Priority: P2 Keywords: InRadar
Version: WebKit Nightly Build   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
Patch
none
Patch
none
Patch
none
Patch
none
Patch for landing none

Description youenn fablet 2020-02-14 14:52:06 PST
Add WebInspector support to WebKit::WebSocketChannel
Comment 1 youenn fablet 2020-02-14 14:55:19 PST
Created attachment 390826 [details]
Patch
Comment 2 youenn fablet 2020-02-14 14:56:55 PST
Created attachment 390827 [details]
Patch
Comment 3 youenn fablet 2020-02-14 16:10:48 PST
Created attachment 390831 [details]
Patch
Comment 4 youenn fablet 2020-02-14 17:56:40 PST
Created attachment 390845 [details]
Patch
Comment 5 Darin Adler 2020-02-16 15:54:09 PST
Comment on attachment 390845 [details]
Patch

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

> Source/WebCore/Modules/websockets/WebSocketChannelInspector.h:50
> +    unsigned long m_progressIdentifier { 0 };

The use of “long” here seems questionable. An unsigned is already 32 bits, just like an unsigned long.

> Source/WebKit/WebProcess/Network/WebSocketChannel.cpp:53
> +    WebSocketFrame frame(opCode, true, false, true, data, length);

Sure seems mysterious, written like this.
Comment 6 youenn fablet 2020-02-17 10:41:50 PST
Created attachment 390936 [details]
Patch for landing
Comment 7 youenn fablet 2020-02-17 10:47:34 PST
(In reply to Darin Adler from comment #5)
> Comment on attachment 390845 [details]
> Patch
> 
> View in context:
> https://bugs.webkit.org/attachment.cgi?id=390845&action=review
> 
> > Source/WebCore/Modules/websockets/WebSocketChannelInspector.h:50
> > +    unsigned long m_progressIdentifier { 0 };

Changed it to unsigned.

> The use of “long” here seems questionable. An unsigned is already 32 bits,
> just like an unsigned long.
> 
> > Source/WebKit/WebProcess/Network/WebSocketChannel.cpp:53
> > +    WebSocketFrame frame(opCode, true, false, true, data, length);
> 
> Sure seems mysterious, written like this.

Reused the other routine that is indeed clearer.
Comment 9 WebKit Commit Bot 2020-02-17 12:46:48 PST
Comment on attachment 390936 [details]
Patch for landing

Clearing flags on attachment: 390936

Committed r256762: <https://trac.webkit.org/changeset/256762>
Comment 10 WebKit Commit Bot 2020-02-17 12:46:49 PST
All reviewed patches have been landed.  Closing bug.
Comment 11 Radar WebKit Bug Importer 2020-02-17 12:47:14 PST
<rdar://problem/59522008>