Tue, 06 Jan 2015 21:39:09 +0100
Conditionally force memory storage according to privacy.thirdparty.isolate;
This solves Tor bug #9701, complying with disk avoidance documented in
https://www.torproject.org/projects/torbrowser/design/#disk-avoidance.
1 <!DOCTYPE HTML>
2 <html>
3 <!--
4 https://bugzilla.mozilla.org/show_bug.cgi?id=405178
5 -->
6 <head>
7 <title>Test for Bug 405178</title>
8 <script type="text/javascript" src="/tests/SimpleTest/SimpleTest.js"></script>
9 <link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css" />
10 </head>
11 <body>
12 <a target="_blank" href="https://bugzilla.mozilla.org/show_bug.cgi?id=405178">Mozilla Bug 405178</a>
13 <p id="display"><div id="div" style="-moz-column-width: 10px;">孑ۍ </div></p>
14 <div id="content" style="display: none">
16 </div>
17 <pre id="test">
18 <script class="testbody" type="text/javascript">
20 /** Test for Bug 405178 **/
22 var div, textNode;
24 function boom()
25 {
26 div = document.getElementById("div");
27 textNode = div.firstChild;
29 div.removeChild(textNode);
30 setTimeout(boom2, 200);
31 }
33 function boom2()
34 {
35 textNode.data = "";
36 div.appendChild(document.createTextNode("X"))
37 var foo = document.body.offsetHeight;
39 ok(true, "Test is successful if we get here without crashing");
40 SimpleTest.finish();
41 }
43 SimpleTest.waitForExplicitFinish();
44 addLoadEvent(boom);
46 </script>
47 </pre>
48 </body>
49 </html>