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

Side by Side Diff: net/proxy/proxy_script_fetcher_impl.cc

Issue 1003953008: Remove prerender cookie store, part 4. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@prerender-revert-cookie-store-3
Patch Set: rebase (just in case since this is so huge) Created 5 years, 9 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
« no previous file with comments | « net/ocsp/nss_ocsp.cc ('k') | net/spdy/spdy_network_transaction_unittest.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 "net/proxy/proxy_script_fetcher_impl.h" 5 #include "net/proxy/proxy_script_fetcher_impl.h"
6 6
7 #include "base/compiler_specific.h" 7 #include "base/compiler_specific.h"
8 #include "base/logging.h" 8 #include "base/logging.h"
9 #include "base/message_loop/message_loop.h" 9 #include "base/message_loop/message_loop.h"
10 #include "base/profiler/scoped_tracker.h" 10 #include "base/profiler/scoped_tracker.h"
(...skipping 115 matching lines...) Expand 10 before | Expand all | Expand 10 after
126 std::string charset; 126 std::string charset;
127 std::string data; 127 std::string data;
128 if (!DataURL::Parse(url, &mime_type, &charset, &data)) 128 if (!DataURL::Parse(url, &mime_type, &charset, &data))
129 return ERR_FAILED; 129 return ERR_FAILED;
130 130
131 ConvertResponseToUTF16(charset, data, text); 131 ConvertResponseToUTF16(charset, data, text);
132 return OK; 132 return OK;
133 } 133 }
134 134
135 cur_request_ = 135 cur_request_ =
136 url_request_context_->CreateRequest(url, DEFAULT_PRIORITY, this, NULL); 136 url_request_context_->CreateRequest(url, DEFAULT_PRIORITY, this);
137 cur_request_->set_method("GET"); 137 cur_request_->set_method("GET");
138 138
139 // Make sure that the PAC script is downloaded using a direct connection, 139 // Make sure that the PAC script is downloaded using a direct connection,
140 // to avoid circular dependencies (fetching is a part of proxy resolution). 140 // to avoid circular dependencies (fetching is a part of proxy resolution).
141 // Also disable the use of the disk cache. The cache is disabled so that if 141 // Also disable the use of the disk cache. The cache is disabled so that if
142 // the user switches networks we don't potentially use the cached response 142 // the user switches networks we don't potentially use the cached response
143 // from old network when we should in fact be re-fetching on the new network. 143 // from old network when we should in fact be re-fetching on the new network.
144 // If the PAC script is hosted on an HTTPS server we bypass revocation 144 // If the PAC script is hosted on an HTTPS server we bypass revocation
145 // checking in order to avoid a circular dependency when attempting to fetch 145 // checking in order to avoid a circular dependency when attempting to fetch
146 // the OCSP response or CRL. We could make the revocation check go direct but 146 // the OCSP response or CRL. We could make the revocation check go direct but
(...skipping 175 matching lines...) Expand 10 before | Expand all | Expand 10 after
322 // is still applicable. 322 // is still applicable.
323 if (cur_request_id_ != id) 323 if (cur_request_id_ != id)
324 return; 324 return;
325 325
326 DCHECK(cur_request_.get()); 326 DCHECK(cur_request_.get());
327 result_code_ = ERR_TIMED_OUT; 327 result_code_ = ERR_TIMED_OUT;
328 cur_request_->Cancel(); 328 cur_request_->Cancel();
329 } 329 }
330 330
331 } // namespace net 331 } // namespace net
OLDNEW
« no previous file with comments | « net/ocsp/nss_ocsp.cc ('k') | net/spdy/spdy_network_transaction_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698