summaryrefslogtreecommitdiffstats
path: root/net/tools
diff options
context:
space:
mode:
Diffstat (limited to 'net/tools')
-rw-r--r--net/tools/crash_cache/crash_cache.cc10
-rw-r--r--net/tools/dump_cache/cache_dumper.cc8
-rw-r--r--net/tools/dump_cache/cache_dumper.h12
-rw-r--r--net/tools/dump_cache/upgrade.cc12
-rw-r--r--net/tools/fetch/fetch_client.cc4
5 files changed, 23 insertions, 23 deletions
diff --git a/net/tools/crash_cache/crash_cache.cc b/net/tools/crash_cache/crash_cache.cc
index 57fa32c..45bcb87 100644
--- a/net/tools/crash_cache/crash_cache.cc
+++ b/net/tools/crash_cache/crash_cache.cc
@@ -126,7 +126,7 @@ bool CreateTargetFolder(const FilePath& path, RankCrashes action,
// Makes sure that any pending task is processed.
void FlushQueue(disk_cache::Backend* cache) {
- TestCompletionCallback cb;
+ TestOldCompletionCallback cb;
int rv =
reinterpret_cast<disk_cache::BackendImpl*>(cache)->FlushQueueForTest(&cb);
cb.GetResult(rv); // Ignore the result;
@@ -135,7 +135,7 @@ void FlushQueue(disk_cache::Backend* cache) {
// Generates the files for an empty and one item cache.
int SimpleInsert(const FilePath& path, RankCrashes action,
base::Thread* cache_thread) {
- TestCompletionCallback cb;
+ TestOldCompletionCallback cb;
disk_cache::Backend* cache;
int rv = disk_cache::CreateCacheBackend(net::DISK_CACHE, path, 0, false,
cache_thread->message_loop_proxy(),
@@ -175,7 +175,7 @@ int SimpleRemove(const FilePath& path, RankCrashes action,
DCHECK(action >= disk_cache::REMOVE_ONE_1);
DCHECK(action <= disk_cache::REMOVE_TAIL_3);
- TestCompletionCallback cb;
+ TestOldCompletionCallback cb;
disk_cache::Backend* cache;
// Use a simple LRU for eviction.
int rv = disk_cache::CreateCacheBackend(net::MEDIA_CACHE, path, 0, false,
@@ -218,7 +218,7 @@ int HeadRemove(const FilePath& path, RankCrashes action,
DCHECK(action >= disk_cache::REMOVE_HEAD_1);
DCHECK(action <= disk_cache::REMOVE_HEAD_4);
- TestCompletionCallback cb;
+ TestOldCompletionCallback cb;
disk_cache::Backend* cache;
// Use a simple LRU for eviction.
int rv = disk_cache::CreateCacheBackend(net::MEDIA_CACHE, path, 0, false,
@@ -264,7 +264,7 @@ int LoadOperations(const FilePath& path, RankCrashes action,
if (!cache || !cache->SetMaxSize(0x100000))
return GENERIC;
- TestCompletionCallback cb;
+ TestOldCompletionCallback cb;
int rv = cache->Init(&cb);
if (cb.GetResult(rv) != net::OK || cache->GetEntryCount())
return GENERIC;
diff --git a/net/tools/dump_cache/cache_dumper.cc b/net/tools/dump_cache/cache_dumper.cc
index 0335516..8e830fa 100644
--- a/net/tools/dump_cache/cache_dumper.cc
+++ b/net/tools/dump_cache/cache_dumper.cc
@@ -15,13 +15,13 @@
int CacheDumper::CreateEntry(const std::string& key,
disk_cache::Entry** entry,
- net::CompletionCallback* callback) {
+ net::OldCompletionCallback* callback) {
return cache_->CreateEntry(key, entry, callback);
}
int CacheDumper::WriteEntry(disk_cache::Entry* entry, int index, int offset,
net::IOBuffer* buf, int buf_len,
- net::CompletionCallback* callback) {
+ net::OldCompletionCallback* callback) {
return entry->WriteData(index, offset, buf, buf_len, callback, false);
}
@@ -66,7 +66,7 @@ bool SafeCreateDirectory(const std::wstring& path) {
int DiskDumper::CreateEntry(const std::string& key,
disk_cache::Entry** entry,
- net::CompletionCallback* callback) {
+ net::OldCompletionCallback* callback) {
FilePath path(path_);
// The URL may not start with a valid protocol; search for it.
int urlpos = key.find("http");
@@ -147,7 +147,7 @@ void GetNormalizedHeaders(const net::HttpResponseInfo& info,
int DiskDumper::WriteEntry(disk_cache::Entry* entry, int index, int offset,
net::IOBuffer* buf, int buf_len,
- net::CompletionCallback* callback) {
+ net::OldCompletionCallback* callback) {
if (!entry_)
return 0;
diff --git a/net/tools/dump_cache/cache_dumper.h b/net/tools/dump_cache/cache_dumper.h
index 03c7ac9..a062026 100644
--- a/net/tools/dump_cache/cache_dumper.h
+++ b/net/tools/dump_cache/cache_dumper.h
@@ -30,13 +30,13 @@ class CacheDumpWriter {
// Returns a net error code.
virtual int CreateEntry(const std::string& key,
disk_cache::Entry** entry,
- net::CompletionCallback* callback) = 0;
+ net::OldCompletionCallback* callback) = 0;
// Write to the current entry.
// Returns a net error code.
virtual int WriteEntry(disk_cache::Entry* entry, int stream, int offset,
net::IOBuffer* buf, int buf_len,
- net::CompletionCallback* callback) = 0;
+ net::OldCompletionCallback* callback) = 0;
// Close the current entry.
virtual void CloseEntry(disk_cache::Entry* entry, base::Time last_used,
@@ -49,10 +49,10 @@ class CacheDumper : public CacheDumpWriter {
explicit CacheDumper(disk_cache::Backend* cache) : cache_(cache) {}
virtual int CreateEntry(const std::string& key, disk_cache::Entry** entry,
- net::CompletionCallback* callback);
+ net::OldCompletionCallback* callback);
virtual int WriteEntry(disk_cache::Entry* entry, int stream, int offset,
net::IOBuffer* buf, int buf_len,
- net::CompletionCallback* callback);
+ net::OldCompletionCallback* callback);
virtual void CloseEntry(disk_cache::Entry* entry, base::Time last_used,
base::Time last_modified);
@@ -67,10 +67,10 @@ class DiskDumper : public CacheDumpWriter {
file_util::CreateDirectory(FilePath(path));
}
virtual int CreateEntry(const std::string& key, disk_cache::Entry** entry,
- net::CompletionCallback* callback);
+ net::OldCompletionCallback* callback);
virtual int WriteEntry(disk_cache::Entry* entry, int stream, int offset,
net::IOBuffer* buf, int buf_len,
- net::CompletionCallback* callback);
+ net::OldCompletionCallback* callback);
virtual void CloseEntry(disk_cache::Entry* entry, base::Time last_used,
base::Time last_modified);
diff --git a/net/tools/dump_cache/upgrade.cc b/net/tools/dump_cache/upgrade.cc
index 80d97b3..60a0d35 100644
--- a/net/tools/dump_cache/upgrade.cc
+++ b/net/tools/dump_cache/upgrade.cc
@@ -266,8 +266,8 @@ class MasterSM : public BaseSM {
CacheDumpWriter* writer_;
const std::wstring& path_;
bool dump_to_disk_;
- net::CompletionCallbackImpl<MasterSM> create_callback_;
- net::CompletionCallbackImpl<MasterSM> write_callback_;
+ net::OldCompletionCallbackImpl<MasterSM> create_callback_;
+ net::OldCompletionCallbackImpl<MasterSM> write_callback_;
};
void MasterSM::OnIOCompleted(MessageLoopForIO::IOContext* context,
@@ -323,7 +323,7 @@ bool MasterSM::DoInit() {
writer_ = new DiskDumper(path_);
} else {
disk_cache::Backend* cache;
- TestCompletionCallback cb;
+ TestOldCompletionCallback cb;
int rv = disk_cache::CreateCacheBackend(net::DISK_CACHE,
FilePath::FromWStringHack(path_), 0,
false,
@@ -592,8 +592,8 @@ class SlaveSM : public BaseSM {
void* iterator_;
Message msg_; // Used for DoReadDataComplete and DoGetEntryComplete.
- net::CompletionCallbackImpl<SlaveSM> read_callback_;
- net::CompletionCallbackImpl<SlaveSM> next_callback_;
+ net::OldCompletionCallbackImpl<SlaveSM> read_callback_;
+ net::OldCompletionCallbackImpl<SlaveSM> next_callback_;
scoped_ptr<disk_cache::BackendImpl> cache_;
};
@@ -604,7 +604,7 @@ SlaveSM::SlaveSM(const std::wstring& path, HANDLE channel)
ALLOW_THIS_IN_INITIALIZER_LIST(
next_callback_(this, &SlaveSM::DoGetEntryComplete)) {
disk_cache::Backend* cache;
- TestCompletionCallback cb;
+ TestOldCompletionCallback cb;
int rv = disk_cache::CreateCacheBackend(net::DISK_CACHE,
FilePath::FromWStringHack(path), 0,
false,
diff --git a/net/tools/fetch/fetch_client.cc b/net/tools/fetch/fetch_client.cc
index 4556080..7c1b0f3 100644
--- a/net/tools/fetch/fetch_client.cc
+++ b/net/tools/fetch/fetch_client.cc
@@ -113,8 +113,8 @@ class Client {
net::HttpRequestInfo request_info_;
scoped_ptr<net::HttpTransaction> transaction_;
scoped_refptr<net::IOBuffer> buffer_;
- net::CompletionCallbackImpl<Client> connect_callback_;
- net::CompletionCallbackImpl<Client> read_callback_;
+ net::OldCompletionCallbackImpl<Client> connect_callback_;
+ net::OldCompletionCallbackImpl<Client> read_callback_;
};
int main(int argc, char** argv) {