mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 853562 - Fix nsTArray::SetCapacity callers in IndexedDB to not look at the return value; r=bent
This commit is contained in:
parent
3a3f711de5
commit
1ce7621697
@ -3936,14 +3936,11 @@ GetAllHelper::DoDatabaseWork(mozIStorageConnection* aConnection)
|
||||
bool hasResult;
|
||||
while (NS_SUCCEEDED((rv = stmt->ExecuteStep(&hasResult))) && hasResult) {
|
||||
if (mCloneReadInfos.Capacity() == mCloneReadInfos.Length()) {
|
||||
if (!mCloneReadInfos.SetCapacity(mCloneReadInfos.Capacity() * 2)) {
|
||||
NS_ERROR("Out of memory!");
|
||||
return NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR;
|
||||
}
|
||||
mCloneReadInfos.SetCapacity(mCloneReadInfos.Capacity() * 2);
|
||||
}
|
||||
|
||||
StructuredCloneReadInfo* readInfo = mCloneReadInfos.AppendElement();
|
||||
NS_ASSERTION(readInfo, "Shouldn't fail if SetCapacity succeeded!");
|
||||
NS_ASSERTION(readInfo, "Shouldn't fail since SetCapacity succeeded!");
|
||||
|
||||
rv = IDBObjectStore::GetStructuredCloneReadInfoFromStatement(stmt, 0, 1,
|
||||
mDatabase, *readInfo);
|
||||
|
Loading…
Reference in New Issue
Block a user