Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(237)

Side by Side Diff: webkit/browser/blob/blob_storage_controller.cc

Issue 15746017: Move webkit/blob to new locations. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 7 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "webkit/blob/blob_storage_controller.h" 5 #include "webkit/browser/blob/blob_storage_controller.h"
6 6
7 #include "base/logging.h" 7 #include "base/logging.h"
8 #include "googleurl/src/gurl.h" 8 #include "googleurl/src/gurl.h"
9 #include "webkit/blob/blob_data.h" 9 #include "webkit/common/blob/blob_data.h"
10 10
11 namespace webkit_blob { 11 namespace webkit_blob {
12 12
13 namespace { 13 namespace {
14 14
15 // We can't use GURL directly for these hash fragment manipulations 15 // We can't use GURL directly for these hash fragment manipulations
16 // since it doesn't have specific knowlege of the BlobURL format. GURL 16 // since it doesn't have specific knowlege of the BlobURL format. GURL
17 // treats BlobURLs as if they were PathURLs which don't support hash 17 // treats BlobURLs as if they were PathURLs which don't support hash
18 // fragments. 18 // fragments.
19 19
(...skipping 228 matching lines...) Expand 10 before | Expand all | Expand 10 after
248 bool BlobStorageController::DecrementBlobDataUsage(BlobData* blob_data) { 248 bool BlobStorageController::DecrementBlobDataUsage(BlobData* blob_data) {
249 BlobDataUsageMap::iterator found = blob_data_usage_count_.find(blob_data); 249 BlobDataUsageMap::iterator found = blob_data_usage_count_.find(blob_data);
250 DCHECK(found != blob_data_usage_count_.end()); 250 DCHECK(found != blob_data_usage_count_.end());
251 if (--(found->second)) 251 if (--(found->second))
252 return false; // Still in use 252 return false; // Still in use
253 blob_data_usage_count_.erase(found); 253 blob_data_usage_count_.erase(found);
254 return true; 254 return true;
255 } 255 }
256 256
257 } // namespace webkit_blob 257 } // namespace webkit_blob
OLDNEW
« no previous file with comments | « webkit/browser/blob/blob_storage_controller.h ('k') | webkit/browser/blob/blob_storage_controller_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698