Index: storage/browser/blob/blob_memory_controller.cc |
diff --git a/storage/browser/blob/blob_memory_controller.cc b/storage/browser/blob/blob_memory_controller.cc |
index 422cddf748963812aef5869e5d7e35cb3c10fd28..56ad7da49a4d144a896bf85f0aa8a80f63247801 100644 |
--- a/storage/browser/blob/blob_memory_controller.cc |
+++ b/storage/browser/blob/blob_memory_controller.cc |
@@ -492,10 +492,12 @@ base::WeakPtr<QuotaAllocationTask> BlobMemoryController::ReserveFileQuota( |
} |
void BlobMemoryController::NotifyMemoryItemsUsed( |
- std::vector<scoped_refptr<ShareableBlobDataItem>>& items) { |
+ const std::vector<scoped_refptr<ShareableBlobDataItem>>& items) { |
for (const auto& item : items) { |
- DCHECK_EQ(DataElement::TYPE_BYTES, item->item()->type()); |
- DCHECK_EQ(ShareableBlobDataItem::POPULATED_WITH_QUOTA, item->state()); |
+ if (item->item()->type() != DataElement::TYPE_BYTES || |
+ item->state() != ShareableBlobDataItem::POPULATED_WITH_QUOTA) { |
+ continue; |
+ } |
// We don't want to re-add the item if we're currently paging it to disk. |
if (items_paging_to_file_.find(item->item_id()) != |
items_paging_to_file_.end()) { |