Descriptionbindings: Do not use ScriptWrappable::wrap for RemoteDOMWindow.
Custom toV8(EventTarget*) has been handling LocalDOMWindow in a special
manner so that custom toV8(DOMWindow*) is always used. However, when
RemoteDOMWindow, and DOMWindow as their superclass, were introduced, we
didn't add the same support for RemoteDOMWindow nor DOMWindow. It was
wrong.
When toV8(EventTarget*) is called with a RemoteDOMWindow before
installDOMWindow is called, toV8(EventTarget*) calls
RemoteDOMWindow::wrap() and it creates a wrapper. After that, when
installDOMWindow is called, the wrapper already exists for the
RemoteDOMWindow and it causes crash.
I think this is the cause of mysterious crashes around installDOMWindow.
This CL fixes:
- Makes sure that DOMWindow::wrap is never called.
- Calls toV8(DOMWindow*) for not only LocalDOMWindow but also
RemoteDOMWindow.
I've confirmed that crash occurs at www.nhl.com with --site-per-process
specified, and fix with this CL.
BUG=478890, 477410, 475880
Committed: https://src.chromium.org/viewvc/blink?view=rev&revision=194193
Patch Set 1 #Patch Set 2 : Fixed compile error with MSVC. #Patch Set 3 : Synced. #Patch Set 4 : Fixed ActivityLoggerTest. #
Messages
Total messages: 10 (4 generated)
|