diff options
author | paivanof@gmail.com <paivanof@gmail.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-07-23 17:15:10 +0000 |
---|---|---|
committer | paivanof@gmail.com <paivanof@gmail.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-07-23 17:15:10 +0000 |
commit | 36ffc73476203ce0ab507e79e481702e317a6922 (patch) | |
tree | 8dde21160cfeb6e5ae42643470226f19bd2e6b2d /content/browser/tcmalloc_internals_request_job.cc | |
parent | 9b000129350fe5a26574a013c44915b23acf2918 (diff) | |
download | chromium_src-36ffc73476203ce0ab507e79e481702e317a6922.zip chromium_src-36ffc73476203ce0ab507e79e481702e317a6922.tar.gz chromium_src-36ffc73476203ce0ab507e79e481702e317a6922.tar.bz2 |
Offload disk accesses to WorkerPool in ExtensionProtocolHandler
and URLRequestResourceBundleJob.
To achieve that URLRequestSimpleJob::GetData() signature changed
to allow async operation finishing. All places implementing GetData()
are updated.
Patch from Pavel Ivanov <paivanof@gmail.com>
BUG=59849,90207
Review URL: https://chromiumcodereview.appspot.com/10696135
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@147869 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'content/browser/tcmalloc_internals_request_job.cc')
-rw-r--r-- | content/browser/tcmalloc_internals_request_job.cc | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/content/browser/tcmalloc_internals_request_job.cc b/content/browser/tcmalloc_internals_request_job.cc index 709ec66..5b0c45b 100644 --- a/content/browser/tcmalloc_internals_request_job.cc +++ b/content/browser/tcmalloc_internals_request_job.cc @@ -10,6 +10,7 @@ #include "content/public/browser/browser_thread.h" #include "content/public/browser/render_process_host.h" #include "content/public/common/process_type.h" +#include "net/base/net_errors.h" namespace content { @@ -101,9 +102,11 @@ void AboutTcmalloc(std::string* data) { } #endif -bool TcmallocInternalsRequestJob::GetData(std::string* mime_type, - std::string* charset, - std::string* data) const { +int TcmallocInternalsRequestJob::GetData( + std::string* mime_type, + std::string* charset, + std::string* data, + const net::CompletionCallback& callback) const { mime_type->assign("text/html"); charset->assign("UTF8"); @@ -111,7 +114,7 @@ bool TcmallocInternalsRequestJob::GetData(std::string* mime_type, #if defined(USE_TCMALLOC) AboutTcmalloc(data); #endif - return true; + return net::OK; } } // namespace content |