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

Side by Side Diff: mojo/services/network/url_loader_impl.cc

Issue 354693004: Switch to using URLRequestContextBuilder to create some URLRequestContexts. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Update comments Created 6 years, 5 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 | Annotate | Revision Log
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 "mojo/services/network/url_loader_impl.h" 5 #include "mojo/services/network/url_loader_impl.h"
6 6
7 #include "base/message_loop/message_loop.h"
7 #include "mojo/common/common_type_converters.h" 8 #include "mojo/common/common_type_converters.h"
8 #include "mojo/services/network/network_context.h" 9 #include "mojo/services/network/network_context.h"
9 #include "net/base/io_buffer.h" 10 #include "net/base/io_buffer.h"
10 #include "net/base/load_flags.h" 11 #include "net/base/load_flags.h"
11 #include "net/http/http_response_headers.h" 12 #include "net/http/http_response_headers.h"
12 13
13 namespace mojo { 14 namespace mojo {
14 namespace { 15 namespace {
15 16
16 const uint32_t kMaxReadSize = 64 * 1024; 17 const uint32_t kMaxReadSize = 64 * 1024;
(...skipping 227 matching lines...) Expand 10 before | Expand all | Expand 10 after
244 if (completed_synchronously) { 245 if (completed_synchronously) {
245 base::MessageLoop::current()->PostTask( 246 base::MessageLoop::current()->PostTask(
246 FROM_HERE, 247 FROM_HERE,
247 base::Bind(&URLLoaderImpl::ReadMore, weak_ptr_factory_.GetWeakPtr())); 248 base::Bind(&URLLoaderImpl::ReadMore, weak_ptr_factory_.GetWeakPtr()));
248 } else { 249 } else {
249 ReadMore(); 250 ReadMore();
250 } 251 }
251 } 252 }
252 253
253 } // namespace mojo 254 } // namespace mojo
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698