зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1434308 - IndexedDB must use DifferentProcess scope in StructuredClone, r=sfink
This commit is contained in:
Родитель
ef3c58e0e6
Коммит
68f4120a93
|
@ -74,7 +74,7 @@ struct IDBObjectStore::StructuredCloneWriteInfo
|
|||
uint64_t mOffsetToKeyProp;
|
||||
|
||||
explicit StructuredCloneWriteInfo(IDBDatabase* aDatabase)
|
||||
: mCloneBuffer(JS::StructuredCloneScope::SameProcessSameThread, nullptr,
|
||||
: mCloneBuffer(JS::StructuredCloneScope::DifferentProcess, nullptr,
|
||||
nullptr)
|
||||
, mDatabase(aDatabase)
|
||||
, mOffsetToKeyProp(0)
|
||||
|
@ -1330,7 +1330,7 @@ IDBObjectStore::DeserializeValue(JSContext* aCx,
|
|||
// FIXME: Consider to use StructuredCloneHolder here and in other
|
||||
// deserializing methods.
|
||||
if (!JS_ReadStructuredClone(aCx, aCloneReadInfo.mData, JS_STRUCTURED_CLONE_VERSION,
|
||||
JS::StructuredCloneScope::SameProcessSameThread,
|
||||
JS::StructuredCloneScope::DifferentProcess,
|
||||
aValue, &callbacks, &aCloneReadInfo)) {
|
||||
return false;
|
||||
}
|
||||
|
@ -1502,7 +1502,7 @@ private:
|
|||
|
||||
if (!JS_ReadStructuredClone(aCx, mCloneReadInfo.mData,
|
||||
JS_STRUCTURED_CLONE_VERSION,
|
||||
JS::StructuredCloneScope::SameProcessSameThread,
|
||||
JS::StructuredCloneScope::DifferentProcess,
|
||||
aValue, &callbacks, &mCloneReadInfo)) {
|
||||
return NS_ERROR_DOM_DATA_CLONE_ERR;
|
||||
}
|
||||
|
@ -1615,7 +1615,7 @@ private:
|
|||
|
||||
if (!JS_ReadStructuredClone(aCx, mCloneReadInfo.mData,
|
||||
JS_STRUCTURED_CLONE_VERSION,
|
||||
JS::StructuredCloneScope::SameProcessSameThread,
|
||||
JS::StructuredCloneScope::DifferentProcess,
|
||||
aValue, &callbacks, &mCloneReadInfo)) {
|
||||
return NS_ERROR_DOM_DATA_CLONE_ERR;
|
||||
}
|
||||
|
|
Загрузка…
Ссылка в новой задаче