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

Side by Side Diff: net/disk_cache/backend_impl.cc

Issue 2657005: Get rid of DISALLOW_EVIL_CONSTRUCTORS macro usage in our code base. (Closed) Base URL: git://git.chromium.org/chromium.git
Patch Set: added the macro back Created 10 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
« no previous file with comments | « net/disk_cache/backend_impl.h ('k') | net/disk_cache/block_files.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2006-2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 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 "net/disk_cache/backend_impl.h" 5 #include "net/disk_cache/backend_impl.h"
6 6
7 #include "base/field_trial.h" 7 #include "base/field_trial.h"
8 #include "base/file_path.h" 8 #include "base/file_path.h"
9 #include "base/file_util.h" 9 #include "base/file_util.h"
10 #include "base/histogram.h" 10 #include "base/histogram.h"
11 #include "base/message_loop.h" 11 #include "base/message_loop.h"
(...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after
77 class CleanupTask : public Task { 77 class CleanupTask : public Task {
78 public: 78 public:
79 CleanupTask(const FilePath& path, const std::string& name) 79 CleanupTask(const FilePath& path, const std::string& name)
80 : path_(path), name_(name) {} 80 : path_(path), name_(name) {}
81 81
82 virtual void Run(); 82 virtual void Run();
83 83
84 private: 84 private:
85 FilePath path_; 85 FilePath path_;
86 std::string name_; 86 std::string name_;
87 DISALLOW_EVIL_CONSTRUCTORS(CleanupTask); 87 DISALLOW_COPY_AND_ASSIGN(CleanupTask);
88 }; 88 };
89 89
90 void CleanupTask::Run() { 90 void CleanupTask::Run() {
91 for (int i = 0; i < kMaxOldFolders; i++) { 91 for (int i = 0; i < kMaxOldFolders; i++) {
92 FilePath to_delete = GetPrefixedName(path_, name_, i); 92 FilePath to_delete = GetPrefixedName(path_, name_, i);
93 disk_cache::DeleteCache(to_delete, true); 93 disk_cache::DeleteCache(to_delete, true);
94 } 94 }
95 } 95 }
96 96
97 // Returns a full path to rename the current cache, in order to delete it. path 97 // Returns a full path to rename the current cache, in order to delete it. path
(...skipping 1601 matching lines...) Expand 10 before | Expand all | Expand 10 after
1699 1699
1700 return num_dirty; 1700 return num_dirty;
1701 } 1701 }
1702 1702
1703 bool BackendImpl::CheckEntry(EntryImpl* cache_entry) { 1703 bool BackendImpl::CheckEntry(EntryImpl* cache_entry) {
1704 RankingsNode* rankings = cache_entry->rankings()->Data(); 1704 RankingsNode* rankings = cache_entry->rankings()->Data();
1705 return !rankings->dummy; 1705 return !rankings->dummy;
1706 } 1706 }
1707 1707
1708 } // namespace disk_cache 1708 } // namespace disk_cache
OLDNEW
« no previous file with comments | « net/disk_cache/backend_impl.h ('k') | net/disk_cache/block_files.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698