| Summary: | NetworkSocketChannel should delay sending back error message as done by NetworkSocketStream | ||||||
|---|---|---|---|---|---|---|---|
| Product: | WebKit | Reporter: | youenn fablet <youennf> | ||||
| Component: | WebCore Misc. | Assignee: | youenn fablet <youennf> | ||||
| Status: | RESOLVED FIXED | ||||||
| Severity: | Normal | CC: | achristensen, webkit-bug-importer | ||||
| Priority: | P2 | Keywords: | InRadar | ||||
| Version: | WebKit Local Build | ||||||
| Hardware: | Unspecified | ||||||
| OS: | Unspecified | ||||||
| Attachments: |
|
||||||
|
Description
youenn fablet
2020-08-17 03:17:58 PDT
Created attachment 406709 [details]
Patch
Comment on attachment 406709 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=406709&action=review > Source/WebKit/NetworkProcess/NetworkSocketChannel.h:94 > + String m_errorMessage; It would be nice if we could make a version of Timer::startOneShot that takes a lambda so these could be in a lambda capture instead of members of this object. > Source/WebKit/NetworkProcess/NetworkSocketChannel.h:95 > + Optional<std::pair<unsigned short, String>> m_closeInfo; Could we make this uint16_t? (In reply to Alex Christensen from comment #2) > Comment on attachment 406709 [details] > Patch > > View in context: > https://bugs.webkit.org/attachment.cgi?id=406709&action=review > > > Source/WebKit/NetworkProcess/NetworkSocketChannel.h:94 > > + String m_errorMessage; > > It would be nice if we could make a version of Timer::startOneShot that > takes a lambda so these could be in a lambda capture instead of members of > this object. Agreed, but here we have two call sites, one for the error message and one for code and reason. > > Source/WebKit/NetworkProcess/NetworkSocketChannel.h:95 > > + Optional<std::pair<unsigned short, String>> m_closeInfo; > > Could we make this uint16_t? We probably could since it is an unsigned short for WebIDL as well. But this would not be very consistent with other parts of the WebSocket implementation. Committed r265814: <https://trac.webkit.org/changeset/265814> All reviewed patches have been landed. Closing bug and clearing flags on attachment 406709 [details]. |