Bug 31327

Summary: Clean up SocketStreamHandleClient interface
Product: WebKit Reporter: Alexey Proskuryakov <ap>
Component: WebCore Misc.Assignee: Alexey Proskuryakov <ap>
Status: RESOLVED FIXED    
Severity: Normal CC: ukai
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: All   
OS: All   
Attachments:
Description Flags
proposed patch sam: review+

Description Alexey Proskuryakov 2009-11-10 16:57:37 PST
Patch with comments forthcoming.
Comment 1 Alexey Proskuryakov 2009-11-10 17:02:33 PST
Created attachment 42911 [details]
proposed patch

We should add a comment explaining what the difference between close() and disconnect() is. It's not sufficiently clear to me yet.
Comment 2 Fumitoshi Ukai 2009-11-11 00:57:58 PST
(In reply to comment #1)
> Created an attachment (id=42911) [details]
> proposed patch
> 
> We should add a comment explaining what the difference between close() and
> disconnect() is. It's not sufficiently clear to me yet.

disconnect() is used before WebSocketChannelClient is deleted, because it won't receive didClose() anymore.
On the other hand, close() will imply didClose() that will be called back later.
Comment 3 Alexey Proskuryakov 2009-11-11 09:23:36 PST
Committed <http://trac.webkit.org/changeset/50811>

> disconnect() is used before WebSocketChannelClient is deleted, because it won't
> receive didClose() anymore.
> On the other hand, close() will imply didClose() that will be called back
> later.

Thank you - I added a comment about the difference.