mirror of
https://bitbucket.org/chromiumembedded/cef
synced 2025-06-05 21:39:12 +02:00
Replace ReadOnlySharedMemoryRegion with WritableSharedMemoryRegion (see #3502)
Write access to the shared memory region is required because JavaScript lacks the capability to create read-only ArrayBuffers. When a user attempts to modify an ArrayBuffer that utilizes a ReadOnlySharedMemoryRegion as its BackingStore it triggers an access violation. Note that this pull request may be reverted in the future if JavaScript adds read-only ArrayBuffer support.
This commit is contained in:
committed by
Marshall Greenblatt
parent
f3e92b45fc
commit
8d7001adc3
@@ -44,7 +44,7 @@ void CefBrowserFrame::SendMessage(const std::string& name,
|
||||
|
||||
void CefBrowserFrame::SendSharedMemoryRegion(
|
||||
const std::string& name,
|
||||
base::ReadOnlySharedMemoryRegion region) {
|
||||
base::WritableSharedMemoryRegion region) {
|
||||
// Always send to the newly created RFH, which may be speculative when
|
||||
// navigating cross-origin.
|
||||
if (auto host = GetFrameHost(/*prefer_speculative=*/true)) {
|
||||
|
Reference in New Issue
Block a user