tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

351236-1.html (1123B)


      1 <html><head>
      2 <title>Testcase bug 351236 - Crash [@ nsGetInterface::operator()] with designMode iframes, removing styles, removing iframes, reloading, etc</title>
      3 <script>
      4 function designmodes(i){
      5 try {
      6 window.frames[0].document.designMode='on';
      7 window.frames[0].focus();
      8 window.frames[0].getSelection().collapse(window.frames[0].document.body.childNodes[0],window.frames[0].document.body.childNodes[0].length-2)
      9 window.frames[0].document.execCommand('inserthtml', false, 'tesxt ');
     10 } catch(e) {}
     11 
     12 setTimeout(designmodes,50);
     13 }
     14 
     15 function removestyles(){
     16 document.getElementsByTagName('iframe')[0].removeAttribute('style');
     17 document.getElementsByTagName('q')[0].removeAttribute('style');
     18 }
     19 
     20 function doe() {
     21 setTimeout(designmodes,200);
     22 setTimeout(removestyles,500);
     23 setTimeout(function() {document.removeChild(document.documentElement);}, 1000);
     24 setTimeout(function() {window.location.reload();}, 1500);
     25 }
     26 window.onload=doe;
     27 </script>
     28 
     29 </head>
     30 <body>
     31 This page should not crash Mozilla within 2 seconds<br>
     32 <q style="display: table-row;">
     33 <iframe style="display: table-row;"></iframe>
     34 <iframe></iframe>
     35 </q>
     36 </body>
     37 </html>