| OLD | NEW |
| (Empty) |
| 1 <!DOCTYPE html> | |
| 2 <script src="../resources/js-test.js"></script> | |
| 3 <embed id="testPlugin" logfirstsetwindow="true" type="application/x-webkit-test-
netscape"> | |
| 4 <script> | |
| 5 description("Verify that sync XHRs cancelled by sync NPN message does not crash.
"); | |
| 6 | |
| 7 if (window.testRunner) { | |
| 8 testRunner.dumpAsText(); | |
| 9 testRunner.waitUntilDone(); | |
| 10 } | |
| 11 | |
| 12 function runTest() | |
| 13 { | |
| 14 var plugin = document.getElementById("testPlugin"); | |
| 15 var x = new XMLHttpRequest(); | |
| 16 x.open('GET', '/resources/not-there', false); | |
| 17 // Injecting a call to Evaluate() here will cause the message | |
| 18 // corresponding to logfirstsetwindow's "testRunner.notifyDone()", | |
| 19 // to be synchronously handled during the sync XHR. Which in turn | |
| 20 // triggers the cancellation of the load. | |
| 21 plugin.testEvaluate("1+2;"); | |
| 22 x.send(null); | |
| 23 } | |
| 24 setTimeout(runTest, 1); | |
| 25 </script> | |
| OLD | NEW |