Closed Bug 1367668 Opened 8 years ago Closed 8 years ago

[Payment Request API] Fix the crash due to "Hit MOZ_CRASH(IPC message size is too large) " when doing constructor tests

Categories

(Core :: DOM: Web Payments, enhancement)

enhancement
Not set
normal

Tracking

()

RESOLVED WORKSFORME

People

(Reporter: alchen, Unassigned)

References

(Blocks 1 open bug)

Details

constructor tests: https://w3c-test.org/payment-request/payment-request-constructor.https.html We will meet crash on two test cases. 1. const newDetails = Object.assign({}, defaultDetails, { id: "".padStart(100000000, "\n test 123 \t \n "), }); 2. const recursiveDictionary = {}; recursiveDictionary.foo = recursiveDictionary;
Blocks: 1318987
> 2. > const recursiveDictionary = {}; > recursiveDictionary.foo = recursiveDictionary; We may use CycleDetector for the case. http://searchfox.org/mozilla-central/rev/5e1e8d2f244bd8c210a578ff1f65c3b720efe34e/js/src/json.cpp#299
(In reply to Alphan Chen [:alchen] from comment #0) > 2. > const recursiveDictionary = {}; > recursiveDictionary.foo = recursiveDictionary; The latest Nightly passes the test "Rethrow any exceptions of JSON-serializing paymentMethod.data into a string" https://w3c-test.org/payment-request/payment-request-constructor.https.html
(In reply to Alphan Chen [:alchen] from comment #0) > constructor tests: > https://w3c-test.org/payment-request/payment-request-constructor.https.html > > We will meet crash on two test cases. > > 1. > const newDetails = Object.assign({}, defaultDetails, { > id: "".padStart(100000000, "\n test 123 \t \n "), > }); The latest test has decreased the number and our implementation doesn't crash. https://github.com/w3c/web-platform-tests/blob/master/payment-request/payment-request-constructor.https.html#L44
Resolve as WFM per comment 2 & 3. Feel free to reopen if the bug re-occurs.
Status: NEW → RESOLVED
Closed: 8 years ago
Resolution: --- → WORKSFORME
No longer blocks: 1318987
You need to log in before you can comment on or make changes to this bug.