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

Side by Side Diff: chrome/browser/net/http_pipelining_compatibility_client.cc

Issue 10559036: Added URLRequestContext to constructor for URLRequest. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Merged with latest version Created 8 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
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 "chrome/browser/net/http_pipelining_compatibility_client.h" 5 #include "chrome/browser/net/http_pipelining_compatibility_client.h"
6 6
7 #include "base/metrics/field_trial.h" 7 #include "base/metrics/field_trial.h"
8 #include "base/metrics/histogram.h" 8 #include "base/metrics/histogram.h"
9 #include "base/string_number_conversions.h" 9 #include "base/string_number_conversions.h"
10 #include "base/string_split.h" 10 #include "base/string_split.h"
(...skipping 70 matching lines...) Expand 10 before | Expand all | Expand 10 after
81 int response_code_; 81 int response_code_;
82 }; 82 };
83 83
84 Request::Request(int request_id, 84 Request::Request(int request_id,
85 const std::string& base_url, 85 const std::string& base_url,
86 const RequestInfo& info, 86 const RequestInfo& info,
87 internal::PipelineTestRequest::Delegate* delegate, 87 internal::PipelineTestRequest::Delegate* delegate,
88 net::URLRequestContext* url_request_context) 88 net::URLRequestContext* url_request_context)
89 : delegate_(delegate), 89 : delegate_(delegate),
90 request_id_(request_id), 90 request_id_(request_id),
91 url_request_(new net::URLRequest(GURL(base_url + info.filename), this)), 91 url_request_(new net::URLRequest(GURL(base_url + info.filename),
92 this,
93 url_request_context)),
92 info_(info), 94 info_(info),
93 response_code_(0) { 95 response_code_(0) {
94 url_request_->set_context(url_request_context);
95 url_request_->set_load_flags(net::LOAD_BYPASS_CACHE | 96 url_request_->set_load_flags(net::LOAD_BYPASS_CACHE |
96 net::LOAD_DISABLE_CACHE | 97 net::LOAD_DISABLE_CACHE |
97 net::LOAD_DO_NOT_SAVE_COOKIES | 98 net::LOAD_DO_NOT_SAVE_COOKIES |
98 net::LOAD_DO_NOT_SEND_COOKIES | 99 net::LOAD_DO_NOT_SEND_COOKIES |
99 net::LOAD_DO_NOT_PROMPT_FOR_LOGIN | 100 net::LOAD_DO_NOT_PROMPT_FOR_LOGIN |
100 net::LOAD_DO_NOT_SEND_AUTH_DATA); 101 net::LOAD_DO_NOT_SEND_AUTH_DATA);
101 } 102 }
102 103
103 void Request::Start() { 104 void Request::Start() {
104 url_request_->Start(); 105 url_request_->Start();
(...skipping 420 matching lines...) Expand 10 before | Expand all | Expand 10 after
525 526
526 content::BrowserThread::PostTask( 527 content::BrowserThread::PostTask(
527 content::BrowserThread::IO, 528 content::BrowserThread::IO,
528 FROM_HERE, 529 FROM_HERE,
529 base::Bind(&CollectPipeliningCapabilityStatsOnIOThread, 530 base::Bind(&CollectPipeliningCapabilityStatsOnIOThread,
530 pipeline_test_server, 531 pipeline_test_server,
531 io_thread)); 532 io_thread));
532 } 533 }
533 534
534 } // namespace chrome_browser_net 535 } // namespace chrome_browser_net
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698