tor-browser

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

bug908915.js (1045B)


      1 // |jit-test| error: 42; skip-if: getBuildConfiguration("wasi")
      2 load(libdir + "immutable-prototype.js");
      3 
      4 // Suppress the large quantity of output on stdout (eg from calling
      5 // dumpHeap()).
      6 os.file.redirect(null);
      7 
      8 var ignorelist = {
      9    'quit': true,
     10    'crash': true,
     11    'readline': true,
     12    'terminate': true,
     13    'nukeAllCCWs': true,
     14    'cacheIRHealthReport': true,
     15    'getInnerMostEnvironmentObject': true,
     16    'getEnclosingEnvironmentObject': true,
     17    'getEnvironmentObjectType' : true,
     18 };
     19 
     20 function f(y) {}
     21 for (let e of Object.values(newGlobal())) {
     22    if (e.name in ignorelist)
     23 continue;
     24    print(e.name);
     25    try {
     26        e();
     27    } catch (r) {}
     28 }
     29 (function() {
     30    arguments;
     31    if (globalPrototypeChainIsMutable())
     32        Object.prototype.__proto__ = newGlobal()
     33    function f(y) {
     34        y()
     35    }
     36    var arr = [];
     37    arr.__proto__ = newGlobal();
     38    for (b of Object.values(arr)) {
     39        if (b.name in ignorelist)
     40            continue;
     41        try {
     42            f(b)
     43        } catch (e) {}
     44    }
     45 })();
     46 
     47 throw 42;