js/src/jit-test/tests/auto-regress/bug661840.js

Thu, 15 Jan 2015 15:59:08 +0100

author
Michael Schloh von Bennewitz <michael@schloh.com>
date
Thu, 15 Jan 2015 15:59:08 +0100
branch
TOR_BUG_9701
changeset 10
ac0c01689b40
permissions
-rw-r--r--

Implement a real Private Browsing Mode condition by changing the API/ABI;
This solves Tor bug #9701, complying with disk avoidance documented in
https://www.torproject.org/projects/torbrowser/design/#disk-avoidance.

     1 // |jit-test| error:ReferenceError
     3 // Binary: cache/js-dbg-32-11714be33655-linux
     4 // Flags: -m -n
     5 //
     6 function f(a) {}
     7 s = [{
     8   s: [],
     9   s: function(d, b) {},
    10   t: function() {
    11     try {} catch (e) {}
    12   }
    13 }, {
    14   t: "",
    15   s: [],
    16   s: function(d, b) {}
    17 }, {
    18   t: "",
    19   s: [],
    20   s: function(d, b) {},
    21   t: function() {}
    22 }, {
    23   t: "",
    24   x: "",
    25   s: [],
    26   g: function(b) {},
    27   t: function(f) {}
    28 }, {
    29   t: "",
    30   s: [],
    31   s: function() {}
    32 }];
    33 v = 0
    34 Function("gc(evalcx('lazy'))")();
    35 gczeal();
    36 gc();
    37 (function() {
    38   x
    39 })()

mercurial