Changeset 79972 in webkit


Ignore:
Timestamp:
Feb 28, 2011 11:09:44 PM (13 years ago)
Author:
tonyg@chromium.org
Message:

2011-02-28 Tony Gentilcore <tonyg@chromium.org>

Reviewed by Darin Adler.

Fix a race condition in editing/selection/4975120
https://bugs.webkit.org/show_bug.cgi?id=55429

If the parser yields between the iframe and the script, it would have been
possible for step2() to be called before runTest() and the test would hang.

  • editing/selection/4975120.html:
Location:
trunk/LayoutTests
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/LayoutTests/ChangeLog

    r79971 r79972  
     12011-02-28  Tony Gentilcore  <tonyg@chromium.org>
     2
     3        Reviewed by Darin Adler.
     4
     5        Fix a race condition in editing/selection/4975120
     6        https://bugs.webkit.org/show_bug.cgi?id=55429
     7
     8        If the parser yields between the iframe and the script, it would have been
     9        possible for step2() to be called before runTest() and the test would hang.
     10
     11        * editing/selection/4975120.html:
     12
    1132011-02-28  Benjamin Kalman  <kalman@chromium.org>
    214
  • trunk/LayoutTests/editing/selection/4975120.html

    r49592 r79972  
    11<head>
    22<script>
     3if (window.layoutTestController)
     4    window.layoutTestController.waitUntilDone();
     5
    36function runTest() {
    4     if (window.layoutTestController)
    5         window.layoutTestController.waitUntilDone();
    6 }
    7 
    8 function step2() {
    97    var input = document.getElementById("input");
    108    input.setSelectionRange(0, 3);
     
    2523<p>This tests for a bug that caused the parent of an active frame to paint as though it were active when its window becomes key.  To run manually, make another window active and then make this window active. Only the subframe should appear active.</p>
    2624<input id="input" type="text" value="foo"><br>
    27 <iframe src="../resources/contenteditable-iframe-src.html" onload="step2();"></iframe></body>
     25<iframe src="../resources/contenteditable-iframe-src.html" onload="runTest()"></iframe></body>
    2826
    2927<script>
    30 runTest();
    3128</script>
Note: See TracChangeset for help on using the changeset viewer.