Sat, 03 Jan 2015 20:18:00 +0100
Conditionally enable double key logic according to:
private browsing mode or privacy.thirdparty.isolate preference and
implement in GetCookieStringCommon and FindCookie where it counts...
With some reservations of how to convince FindCookie users to test
condition and pass a nullptr when disabling double key logic.
1 function testNullCallee() {
2 try {
3 function f() {
4 var x = new Array(5);
5 for (var i = 0; i < 5; i++)
6 x[i] = a[i].toString();
7 return x.join(',');
8 }
9 f([[1],[2],[3],[4],[5]]);
10 f([null, null, null, null, null]);
11 } catch (e) {
12 return true;
13 }
14 return false;
15 }
16 assertEq(testNullCallee(), true);