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

Side by Side Diff: net/disk_cache/sparse_control.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/rankings.h ('k') | net/disk_cache/storage_block.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) 2009 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/sparse_control.h" 5 #include "net/disk_cache/sparse_control.h"
6 6
7 #include "base/format_macros.h" 7 #include "base/format_macros.h"
8 #include "base/logging.h" 8 #include "base/logging.h"
9 #include "base/message_loop.h" 9 #include "base/message_loop.h"
10 #include "base/string_util.h" 10 #include "base/string_util.h"
11 #include "base/time.h" 11 #include "base/time.h"
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after
64 friend class base::RefCounted<ChildrenDeleter>; 64 friend class base::RefCounted<ChildrenDeleter>;
65 ~ChildrenDeleter() {} 65 ~ChildrenDeleter() {}
66 66
67 void DeleteChildren(); 67 void DeleteChildren();
68 68
69 disk_cache::BackendImpl* backend_; 69 disk_cache::BackendImpl* backend_;
70 std::string name_; 70 std::string name_;
71 disk_cache::Bitmap children_map_; 71 disk_cache::Bitmap children_map_;
72 int64 signature_; 72 int64 signature_;
73 scoped_array<char> buffer_; 73 scoped_array<char> buffer_;
74 DISALLOW_EVIL_CONSTRUCTORS(ChildrenDeleter); 74 DISALLOW_COPY_AND_ASSIGN(ChildrenDeleter);
75 }; 75 };
76 76
77 // This is the callback of the file operation. 77 // This is the callback of the file operation.
78 void ChildrenDeleter::OnFileIOComplete(int bytes_copied) { 78 void ChildrenDeleter::OnFileIOComplete(int bytes_copied) {
79 char* buffer = buffer_.release(); 79 char* buffer = buffer_.release();
80 Start(buffer, bytes_copied); 80 Start(buffer, bytes_copied);
81 } 81 }
82 82
83 void ChildrenDeleter::Start(char* buffer, int len) { 83 void ChildrenDeleter::Start(char* buffer, int len) {
84 buffer_.reset(buffer); 84 buffer_.reset(buffer);
(...skipping 650 matching lines...) Expand 10 before | Expand all | Expand 10 after
735 net::CompletionCallback* c = abort_callbacks_[i]; 735 net::CompletionCallback* c = abort_callbacks_[i];
736 if (i == abort_callbacks_.size() - 1) 736 if (i == abort_callbacks_.size() - 1)
737 abort_callbacks_.clear(); 737 abort_callbacks_.clear();
738 738
739 entry_->Release(); // Don't touch object after this line. 739 entry_->Release(); // Don't touch object after this line.
740 c->Run(net::OK); 740 c->Run(net::OK);
741 } 741 }
742 } 742 }
743 743
744 } // namespace disk_cache 744 } // namespace disk_cache
OLDNEW
« no previous file with comments | « net/disk_cache/rankings.h ('k') | net/disk_cache/storage_block.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698