| Summary: | [JSC] Rename ArrayBuffer::slice to ArrayBuffer::trySlice and insert appropriate checks | ||||||
|---|---|---|---|---|---|---|---|
| Product: | WebKit | Reporter: | Yusuke Suzuki <ysuzuki> | ||||
| Component: | New Bugs | Assignee: | Yusuke Suzuki <ysuzuki> | ||||
| Status: | NEW --- | ||||||
| Severity: | Normal | CC: | eric.carlson, ews-watchlist, glenn, jer.noble, keith_miller, mark.lam, msaboff, philipj, saam, sergio, tzagallo | ||||
| Priority: | P2 | ||||||
| Version: | WebKit Nightly Build | ||||||
| Hardware: | Unspecified | ||||||
| OS: | Unspecified | ||||||
| Attachments: |
|
||||||
|
Description
Yusuke Suzuki
2020-03-15 04:27:44 PDT
Created attachment 393614 [details]
Patch
Comment on attachment 393614 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=393614&action=review r=me with fix. > Source/WebCore/bindings/js/StructuredClone.cpp:62 > + return JSValue::encode(JSC::throwOutOfMemoryError(globalObject, scope)); /globalObject/lexicalGlobalObject/ > Source/WebCore/bindings/js/StructuredClone.cpp:63 > + return JSValue::encode(JSArrayBuffer::create(lexicalGlobalObject->vm(), lexicalGlobalObject->arrayBufferStructure(ArrayBufferSharingMode::Default), WTFMove(slicedBuffer))); Not due to your change, but can you jut use vm here instead of lexicalGlobalObject->vm()? We've already pre-computed it above. |