Bug 21825 - JSDOMBinding should not blindly cast the global object to JSDOMWindow
Summary: JSDOMBinding should not blindly cast the global object to JSDOMWindow
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebCore JavaScript (show other bugs)
Version: 528+ (Nightly build)
Hardware: Mac OS X 10.5
: P2 Normal
Assignee: Alexey Proskuryakov
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-10-23 01:07 PDT by Alexey Proskuryakov
Modified: 2008-10-23 03:16 PDT (History)
0 users

See Also:


Attachments
proposed fix (8.09 KB, patch)
2008-10-23 01:42 PDT, Alexey Proskuryakov
mjs: review+
Details | Formatted Diff | Diff
A better fix (16.22 KB, patch)
2008-10-23 02:41 PDT, Alexey Proskuryakov
mjs: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Alexey Proskuryakov 2008-10-23 01:07:36 PDT
It might be a worker context, not a JSDOMWindow.

Patch forthcoming.
Comment 1 Alexey Proskuryakov 2008-10-23 01:42:09 PDT
Created attachment 24592 [details]
proposed fix
Comment 2 Maciej Stachowiak 2008-10-23 01:44:48 PDT
Comment on attachment 24592 [details]
proposed fix

r=me
Comment 3 Alexey Proskuryakov 2008-10-23 02:41:55 PDT
Created attachment 24593 [details]
A better fix

As proposed by Maciej on IRC, do not change JavaScriptCore, as the need is WebCore-specific.
Comment 4 Maciej Stachowiak 2008-10-23 02:43:16 PDT
Comment on attachment 24593 [details]
A better fix

r=me assuming it builds and passes tests
Comment 5 Alexey Proskuryakov 2008-10-23 03:16:29 PDT
Committed revision 37806.