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.
michael@0 | 1 | var g = newGlobal(); |
michael@0 | 2 | var dbg = new Debugger; |
michael@0 | 3 | var gw = dbg.addDebuggee(g); |
michael@0 | 4 | var log; |
michael@0 | 5 | var a = []; |
michael@0 | 6 | |
michael@0 | 7 | dbg.onDebuggerStatement = function (frame) { |
michael@0 | 8 | log += 'd'; |
michael@0 | 9 | frame.onStep = function () { |
michael@0 | 10 | // This handler must not wipe out the debuggee's value in JSContext::iterValue. |
michael@0 | 11 | log += 's'; |
michael@0 | 12 | // This will use JSContext::iterValue in the debugger. |
michael@0 | 13 | for (let i of a) |
michael@0 | 14 | log += 'i'; |
michael@0 | 15 | }; |
michael@0 | 16 | }; |
michael@0 | 17 | |
michael@0 | 18 | log = ''; |
michael@0 | 19 | g.eval("debugger; for (let i of [1,2,3]) print(i);"); |
michael@0 | 20 | assertEq(!!log.match(/^ds*$/), true); |