Fix a crash in IndexedDB.

This commit is contained in:
wolfbeast 2019-09-04 21:04:07 +02:00 committed by Roy Tam
commit cfc50f18c4
10 changed files with 102 additions and 39 deletions

View file

@ -430,7 +430,7 @@ IDBCursor::Continue(JSContext* aCx,
}
Key key;
aRv = key.SetFromJSVal(aCx, aKey);
aRv = key.SetFromJSVal(aCx, aKey, /* aCallGetters */ true);
if (aRv.Failed()) {
return;
}
@ -536,7 +536,7 @@ IDBCursor::ContinuePrimaryKey(JSContext* aCx,
}
Key key;
aRv = key.SetFromJSVal(aCx, aKey);
aRv = key.SetFromJSVal(aCx, aKey, /* aCallGetters */ true);
if (aRv.Failed()) {
return;
}
@ -558,7 +558,7 @@ IDBCursor::ContinuePrimaryKey(JSContext* aCx,
}
Key primaryKey;
aRv = primaryKey.SetFromJSVal(aCx, aPrimaryKey);
aRv = primaryKey.SetFromJSVal(aCx, aPrimaryKey, /* aCallGetters */ true);
if (aRv.Failed()) {
return;
}
@ -718,7 +718,7 @@ IDBCursor::Update(JSContext* aCx, JS::Handle<JS::Value> aValue,
const KeyPath& keyPath = objectStore->GetKeyPath();
Key key;
aRv = keyPath.ExtractKey(aCx, aValue, key);
aRv = keyPath.ExtractKey(aCx, aValue, key, /* aCallGetters */ false);
if (aRv.Failed()) {
return nullptr;
}