Changeset 79944 in webkit
- Timestamp:
- Feb 28, 2011 4:54:55 PM (13 years ago)
- Location:
- trunk
- Files:
-
- 3 added
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/LayoutTests/ChangeLog
r79941 r79944 1 2011-02-28 Tony Gentilcore <tonyg@chromium.org> 2 3 Reviewed by Adam Barth. 4 5 Follow HTML5 spec for document.open() a little more closely 6 https://bugs.webkit.org/show_bug.cgi?id=55392 7 8 * fast/parser/double-write-from-closed-iframe-expected.txt: Added. 9 * fast/parser/double-write-from-closed-iframe.html: Added. Prior to this patch, the second write of 'PASS' could fail indeterminately. 10 * fast/parser/script-tests/double-write-from-closed-iframe.js: Added. 11 * fast/regex/script-tests/cross-frame-callable.js: Necessary to close late writes. 12 1 13 2011-02-28 James Robinson <jamesr@chromium.org> 2 14 -
trunk/LayoutTests/fast/regex/script-tests/cross-frame-callable.js
r76180 r79944 9 9 document.body.appendChild(iframe); 10 10 iframe.contentDocument.write('<script>top.doTest(/a/)</script>'); 11 iframe.contentDocument.close(); 11 12 document.write('DONE'); 12 13 -
trunk/Source/WebCore/ChangeLog
r79942 r79944 1 2011-02-28 Tony Gentilcore <tonyg@chromium.org> 2 3 Reviewed by Adam Barth. 4 5 Follow HTML5 spec for document.open() a little more closely 6 https://bugs.webkit.org/show_bug.cgi?id=55392 7 8 See: 3.5.1.4 at http://www.whatwg.org/specs/web-apps/current-work/#dom-document-open. 9 10 The second return check matches the spec. The first return check (isExecutingScript()) 11 was left in place because without it, fast/tokenizer/write-external-script-open.html 12 would fail. It also possible there is a spec bug because FF4 crashes on that test and 13 IE9 prints "FAILURE." The isLoadingMainResource() check was removed because the main 14 resource is always loading while parser->isParsing(). 15 16 Test: fast/parser/double-write-from-closed-iframe.html 17 18 * dom/Document.cpp: 19 (WebCore::Document::open): 20 1 21 2011-02-28 Avi Drissman <avi@google.com> 2 22 -
trunk/Source/WebCore/dom/Document.cpp
r79861 r79944 1893 1893 1894 1894 if (m_frame) { 1895 ScriptableDocumentParser* parser = scriptableDocumentParser(); 1896 if (m_frame->loader()->isLoadingMainResource() || (parser && parser->isParsing() && parser->isExecutingScript())) 1897 return; 1895 if (ScriptableDocumentParser* parser = scriptableDocumentParser()) { 1896 if (parser->isParsing()) { 1897 // FIXME: HTML5 doesn't tell us to check this, it might not be correct. 1898 if (parser->isExecutingScript()) 1899 return; 1900 1901 if (!parser->wasCreatedByScript() && parser->hasInsertionPoint()) 1902 return; 1903 } 1904 } 1898 1905 1899 1906 if (m_frame->loader()->state() == FrameStateProvisional)
Note: See TracChangeset
for help on using the changeset viewer.