Bug 62446

Summary: [Chromium] Worker object may be garbage collected if it doesn't send any messages
Product: WebKit Reporter: Yury Semikhatsky <yurys>
Component: WebKit Misc.Assignee: Yury Semikhatsky <yurys>
Status: RESOLVED FIXED    
Severity: Normal CC: ap, caseq, dimich, dslomov, jianli, levin, pfeldman
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: All   
OS: All   
Attachments:
Description Flags
Test case
none
Patch dimich: review+

Description Yury Semikhatsky 2011-06-10 03:28:53 PDT
Created attachment 96722 [details]
Test case

If there are no references to a dedicated worker object and no messages are sent to its worker context(which would increment unconfirmed messages counter which in turn would protect worker from being collected) then it may be garbage collected before a first message from worker context arrives. See attached page where messages from the worker context never reaches worker object. This works fine on other ports that use in-process workers.
Comment 1 Yury Semikhatsky 2011-06-10 04:07:15 PDT
Created attachment 96729 [details]
Patch
Comment 2 Dmitry Titov 2011-06-10 11:21:32 PDT
Did you mean r? it or is it still in the works?
Comment 3 Yury Semikhatsky 2011-06-14 05:36:55 PDT
(In reply to comment #2)
> Did you mean r? it or is it still in the works?

I wanted to run the test on Chromium to make sure that it passes there. Now the patch is ready for review.
Comment 4 Dmitry Titov 2011-06-14 10:51:57 PDT
Comment on attachment 96729 [details]
Patch

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

r=me
I wonder if it improves flakiness of worker tests run in Chromium.

> Source/WebKit/chromium/ChangeLog:11
> +

"from it context" -> "from its context"
Comment 5 Yury Semikhatsky 2011-06-15 01:26:51 PDT
Committed r88914: <http://trac.webkit.org/changeset/88914>
Comment 6 Yury Semikhatsky 2011-06-15 01:30:34 PDT
(In reply to comment #4)
> (From update of attachment 96729 [details])
> View in context: https://bugs.webkit.org/attachment.cgi?id=96729&action=review
> 
> r=me
> I wonder if it improves flakiness of worker tests run in Chromium.
> 
> > Source/WebKit/chromium/ChangeLog:11
> > +
> 
> "from it context" -> "from its context"

Done.