Bug 55512

Summary: EventQueue needs to be ref counted
Product: WebKit Reporter: Jeremy Orlow <jorlow>
Component: New BugsAssignee: Jeremy Orlow <jorlow>
Status: RESOLVED FIXED    
Severity: Normal CC: abarth, eric, mihaip, webkit.review.bot
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: Other   
OS: OS X 10.5   
Attachments:
Description Flags
Patch
none
Patch mihaip: review+

Description Jeremy Orlow 2011-03-01 14:57:37 PST
EventQueue needs to be ref counted
Comment 1 Jeremy Orlow 2011-03-01 15:00:58 PST
Created attachment 84302 [details]
Patch
Comment 2 Jeremy Orlow 2011-03-01 15:01:10 PST
Please review.
Comment 3 Mihai Parparita 2011-03-01 15:35:05 PST
Comment on attachment 84302 [details]
Patch

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

> Source/WebCore/dom/EventQueue.cpp:94
> +    RefPtr<EventQueue> m_keepAliveDuringIteration = this;

RefPtr<EventQueue> protector(this) is a more common pattern for this:
https://www.google.com/codesearch?as_q=refptr.*protector&vert=chromium

Either way the name shouldn't start with m_ since it's not a member.
Comment 4 Jeremy Orlow 2011-03-01 15:49:24 PST
(In reply to comment #3)
> (From update of attachment 84302 [details])
> View in context: https://bugs.webkit.org/attachment.cgi?id=84302&action=review
> 
> > Source/WebCore/dom/EventQueue.cpp:94
> > +    RefPtr<EventQueue> m_keepAliveDuringIteration = this;
> 
> RefPtr<EventQueue> protector(this) is a more common pattern for this:
> https://www.google.com/codesearch?as_q=refptr.*protector&vert=chromium
> 
> Either way the name shouldn't start with m_ since it's not a member.

Oops...fixed.
Comment 5 Jeremy Orlow 2011-03-01 15:49:46 PST
Created attachment 84313 [details]
Patch
Comment 6 Jeremy Orlow 2011-03-01 15:54:15 PST
Committed r80054: <http://trac.webkit.org/changeset/80054>
Comment 7 WebKit Review Bot 2011-03-01 16:18:04 PST
http://trac.webkit.org/changeset/80054 might have broken Chromium Win Release