Commit ca3da523 authored by cmumford's avatar cmumford Committed by Commit bot

IndexedDB: Zero no longer a valid value for maxCount in getAll().

Prior IDBObjectStore.getAll implementation used zero as the sentinel value
for maxCount to mean unlimited. This change eliminates that check on the
Chrome side. It is now the callers (Blink's) responsibility to pass in a very
large number (MAXUINT) if the intent is to have the response be unbounded.

BUG=457450

Review URL: https://codereview.chromium.org/1138643007

Cr-Commit-Position: refs/heads/master@{#330225}
parent c9e3a7c2
......@@ -745,9 +745,7 @@ void IndexedDBDatabase::GetAllOperation(
IndexedDBTransaction* transaction) {
IDB_TRACE1("IndexedDBDatabase::GetAllOperation", "txn.id", transaction->id());
DCHECK_GE(max_count, 0);
if (!max_count)
max_count = std::numeric_limits<decltype(max_count)>::max();
DCHECK_GT(max_count, 0);
DCHECK(metadata_.object_stores.find(object_store_id) !=
metadata_.object_stores.end());
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment