Evaluate child text content at the time of #prepare-a-script, not evaluation
Previously, classic inline script's source_text to be evaluated is taken from the element's child text content at the time of evaluation. However, according to the spec, this should be the element's child text content at the time of #prepare-a-script. This CL fixes this by taking the element's child text content in ClassicPendingScript's constructor, which is called inside PrepareScript(). This affects the behavior if parser-inserted classic inline <script>'s innerText is modified by JavaScript after <script> is inserted into DOM before its evaluation, and I expect this is extremely rare and doesn't have legitimate use cases. Bug: 686281 Change-Id: I0ef67dd8b71403a7862f24d02394f89c6e916bfd Reviewed-on: https://chromium-review.googlesource.com/1091912Reviewed-by:Kouhei Ueno <kouhei@chromium.org> Commit-Queue: Hiroshige Hayashizaki <hiroshige@chromium.org> Cr-Commit-Position: refs/heads/master@{#567348}
Showing
Please register or sign in to comment