Upon load failure, remove sync script from execution queue.
commitb514b24711b1fb92ebbb84fabf4dfdcfe859e396
authorsigbjornf@opera.com <sigbjornf@opera.com>
Wed, 29 Jul 2015 11:40:18 +0000 (29 11:40 +0000)
committersigbjornf@opera.com <sigbjornf@opera.com>
Wed, 29 Jul 2015 11:40:18 +0000 (29 11:40 +0000)
tree7df650253580ecb7ea9807589460d40812000267
parent5d414e52349043882ab490a04bffe7203b166522
Upon load failure, remove sync script from execution queue.

If a script element is to be loaded synchronously and executed in order,
it's queued for execution before loading. Should that load fail, the
immediate execution of the script,

  https://html.spec.whatwg.org/#execute-the-script-block

should only result in an error event being dispatched.

Implementation-wise, along with signalling error, the failed script must also
be removed from the internal in-order execution queue. We're done with
(not) executing the script and failure to remove it will cause subsequent
processing of the script execution queue to see the script as having failed
to load and re-dispatch an error event.

R=haraken
BUG=503077

Review URL: https://codereview.chromium.org/1263743002

git-svn-id: svn://svn.chromium.org/blink/trunk@199656 bbb929c8-8fbe-4397-9dbb-9b2b20218538
third_party/WebKit/LayoutTests/fast/dom/HTMLScriptElement/script-sync-onerror-not-repeated-expected.txt [new file with mode: 0644]
third_party/WebKit/LayoutTests/fast/dom/HTMLScriptElement/script-sync-onerror-not-repeated.html [new file with mode: 0644]
third_party/WebKit/Source/core/dom/ScriptRunner.cpp