summaryrefslogtreecommitdiffstats
path: root/webkit/blob
diff options
context:
space:
mode:
Diffstat (limited to 'webkit/blob')
-rw-r--r--webkit/blob/blob_url_request_job.cc10
-rw-r--r--webkit/blob/blob_url_request_job.h1
2 files changed, 8 insertions, 3 deletions
diff --git a/webkit/blob/blob_url_request_job.cc b/webkit/blob/blob_url_request_job.cc
index 5103458..62712d5 100644
--- a/webkit/blob/blob_url_request_job.cc
+++ b/webkit/blob/blob_url_request_job.cc
@@ -65,6 +65,12 @@ BlobURLRequestJob::~BlobURLRequestJob() {
}
void BlobURLRequestJob::Start() {
+ // Continue asynchronously.
+ MessageLoop::current()->PostTask(FROM_HERE, NewRunnableMethod(
+ this, &BlobURLRequestJob::DidStart));
+}
+
+void BlobURLRequestJob::DidStart() {
// We only support GET request per the spec.
if (request()->method() != "GET") {
NotifyFailure(net::ERR_METHOD_NOT_SUPPORTED);
@@ -77,9 +83,7 @@ void BlobURLRequestJob::Start() {
return;
}
- // Continue asynchronously.
- MessageLoop::current()->PostTask(FROM_HERE, NewRunnableMethod(
- this, &BlobURLRequestJob::CountSize));
+ CountSize();
}
void BlobURLRequestJob::Kill() {
diff --git a/webkit/blob/blob_url_request_job.h b/webkit/blob/blob_url_request_job.h
index 5445774..780a642 100644
--- a/webkit/blob/blob_url_request_job.h
+++ b/webkit/blob/blob_url_request_job.h
@@ -57,6 +57,7 @@ class BlobURLRequestJob : public URLRequestJob {
void NotifySuccess();
void NotifyFailure(int);
+ void DidStart();
void DidResolve(base::PlatformFileError rv,
const file_util::FileInfo& file_info);
void DidRead(int result);