Wed, 31 Dec 2014 06:09:35 +0100
Cloned upstream origin tor-browser at tor-browser-31.3.0esr-4.5-1-build1
revision ID fc1c9ff7c1b2defdbc039f12214767608f46423f for hacking purpose.
1 // |reftest| skip-if(Android) silentfail
2 /* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
3 /* This Source Code Form is subject to the terms of the Mozilla Public
4 * License, v. 2.0. If a copy of the MPL was not distributed with this
5 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
7 //-----------------------------------------------------------------------------
8 var BUGNUMBER = 280769;
9 var summary = 'Do not overflow 64K boundary in treeDepth';
10 var actual = 'No Crash';
11 var expect = /No Crash|InternalError: allocation size overflow/;
12 var status;
13 var result;
15 printBugNumber(BUGNUMBER);
16 printStatus (summary);
18 expectExitCode(0);
19 expectExitCode(5);
21 status = summary + ' ' + inSection(1) + ' (new RegExp("0|...|99999") ';
23 try
24 {
25 var N = 100 * 1000;
26 var a = new Array(N);
27 for (var i = 0; i != N; ++i) {
28 a[i] = i;
29 }
30 var str = a.join('|'); // str is 0|1|2|3|...|<printed value of N -1>
31 var re = new RegExp(str);
32 re.exec(N - 1);
33 }
34 catch(ex)
35 {
36 actual = ex + '';
37 }
39 print('Done: ' + actual);
41 reportMatch(expect, actual, summary);