2008-12-03 02:14:51 -08:00
|
|
|
<!DOCTYPE HTML>
|
|
|
|
<html>
|
|
|
|
<!--
|
|
|
|
https://bugzilla.mozilla.org/show_bug.cgi?id=448993
|
|
|
|
-->
|
|
|
|
<head>
|
|
|
|
<title>Test for Bug 448993</title>
|
2009-05-06 13:46:04 -07:00
|
|
|
<script type="application/javascript" src="/MochiKit/packed.js"></script>
|
2008-12-03 02:14:51 -08:00
|
|
|
<script type="application/javascript" src="/tests/SimpleTest/SimpleTest.js"></script>
|
|
|
|
<link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css"/>
|
|
|
|
</head>
|
|
|
|
<body>
|
|
|
|
<a target="_blank" href="https://bugzilla.mozilla.org/show_bug.cgi?id=448993">Mozilla Bug 448993</a>
|
|
|
|
<p id="display"></p>
|
|
|
|
<div id="content" style="display: none">
|
|
|
|
|
|
|
|
</div>
|
|
|
|
<pre id="test">
|
|
|
|
<script type="application/javascript">
|
|
|
|
|
|
|
|
/** Test for Bug 448993 **/
|
|
|
|
|
|
|
|
function gc() {
|
|
|
|
netscape.security.PrivilegeManager.enablePrivilege("UniversalXPConnect");
|
|
|
|
window.QueryInterface(Components.interfaces.nsIInterfaceRequestor)
|
|
|
|
.getInterface(Components.interfaces.nsIDOMWindowUtils)
|
|
|
|
.garbageCollect();
|
|
|
|
}
|
|
|
|
|
|
|
|
function runTest() {
|
|
|
|
var a = document.getElementById("a");
|
|
|
|
var b = document.getElementById("b");
|
|
|
|
var c = document.getElementById("c")
|
|
|
|
var r = document.createRange();
|
|
|
|
r.setStart(b, 0);
|
|
|
|
r.setEnd(a, 2);
|
|
|
|
c.appendChild(b);
|
|
|
|
r.extractContents();
|
|
|
|
var s = document.createRange();
|
|
|
|
s.setEnd(b, 0);
|
|
|
|
gc();
|
|
|
|
s.deleteContents();
|
2009-03-18 08:56:55 -07:00
|
|
|
ok(true, "test did not crash");
|
2008-12-03 02:14:51 -08:00
|
|
|
SimpleTest.finish();
|
|
|
|
}
|
|
|
|
|
|
|
|
SimpleTest.waitForExplicitFinish();
|
|
|
|
addLoadEvent(runTest);
|
|
|
|
|
|
|
|
</script>
|
|
|
|
</pre>
|
|
|
|
<div id="a"><span id="b"></span><span id="c"></span></div>
|
|
|
|
</body>
|
|
|
|
</html>
|