Bug 24564 - Add test to ensure that the JS document wrapper is created in the correct context
Summary: Add test to ensure that the JS document wrapper is created in the correct con...
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: DOM (show other bugs)
Version: 528+ (Nightly build)
Hardware: All All
: P2 Normal
Assignee: Pam Greene (IRC:pamg)
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-03-12 15:23 PDT by Pam Greene (IRC:pamg)
Modified: 2009-03-13 09:21 PDT (History)
0 users

See Also:


Attachments
New test + result (2.94 KB, patch)
2009-03-12 15:25 PDT, Pam Greene (IRC:pamg)
ap: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Pam Greene (IRC:pamg) 2009-03-12 15:23:11 PDT
Once upon a time, Chromium had a bug in which the JS wrapper for the document in an inner frame was created using the prototype chain from the outer frame if the document was accessed from the outer frame first. Add a test to catch that.
Comment 1 Pam Greene (IRC:pamg) 2009-03-12 15:25:37 PDT
Created attachment 28560 [details]
New test + result
Comment 2 Alexey Proskuryakov 2009-03-13 03:37:52 PDT
Comment on attachment 28560 [details]
New test + result

r=me

I think that the test could be slightly cleaner if it used iframe onload attribute, rather than relying on some script run in the subframe. But maybe that wouldn't trigger the bug for some reason?
Comment 3 Pam Greene (IRC:pamg) 2009-03-13 09:21:00 PDT
Hm... I'm not certain either. I'll go ahead and land this as it is for now, and ask the creator of the test to further improve it if he can. (It started out using timeouts and polling rather than cross-frame function calls.)

Landed in r41668.