Bug 108390

Summary: Make JSEventListener more robust in the event of the compiled handler being released.
Product: WebKit Reporter: Oliver Hunt <oliver>
Component: New BugsAssignee: Oliver Hunt <oliver>
Status: RESOLVED FIXED    
Severity: Normal    
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
Patch msaboff: review+

Oliver Hunt
Reported 2013-01-30 14:57:52 PST
Make JSEventListener more robust in the event of the compiled handler being released.
Attachments
Patch (3.21 KB, patch)
2013-01-30 15:03 PST, Oliver Hunt
msaboff: review+
Oliver Hunt
Comment 1 2013-01-30 15:03:29 PST
Oliver Hunt
Comment 2 2013-01-30 17:09:52 PST
Geoffrey Garen
Comment 3 2013-01-30 17:09:55 PST
Comment on attachment 185591 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=185591&action=review > Source/WebCore/bindings/js/JSLazyEventListener.cpp:-125 > - // Since we only parse once, there's no need to keep data used for parsing around anymore. > - m_functionName = String(); > - m_code = String(); > - m_eventParameterName = String(); > - m_sourceURL = String(); Why do we need this, given the early return?
Oliver Hunt
Comment 4 2013-01-30 17:30:19 PST
(In reply to comment #3) > (From update of attachment 185591 [details]) > View in context: https://bugs.webkit.org/attachment.cgi?id=185591&action=review > > > Source/WebCore/bindings/js/JSLazyEventListener.cpp:-125 > > - // Since we only parse once, there's no need to keep data used for parsing around anymore. > > - m_functionName = String(); > > - m_code = String(); > > - m_eventParameterName = String(); > > - m_sourceURL = String(); > > Why do we need this, given the early return? So that we maintain correct behaviour - the only reason we hit this is if we want to execute the function so not running the function would result in incorrect behaviour.
Note You need to log in before you can comment on or make changes to this bug.