| OLD | NEW |
| 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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/io_thread.h" | 5 #include "chrome/browser/io_thread.h" |
| 6 | 6 |
| 7 #include "base/command_line.h" | 7 #include "base/command_line.h" |
| 8 #include "base/leak_tracker.h" | 8 #include "base/leak_tracker.h" |
| 9 #include "base/logging.h" | 9 #include "base/logging.h" |
| 10 #include "base/string_number_conversions.h" | 10 #include "base/string_number_conversions.h" |
| (...skipping 253 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 264 globals_->url_security_manager.reset( | 264 globals_->url_security_manager.reset( |
| 265 net::URLSecurityManager::Create(auth_filter_default_credentials, | 265 net::URLSecurityManager::Create(auth_filter_default_credentials, |
| 266 auth_filter_delegate)); | 266 auth_filter_delegate)); |
| 267 | 267 |
| 268 // Determine which schemes are supported. | 268 // Determine which schemes are supported. |
| 269 std::string csv_auth_schemes = "basic,digest,ntlm,negotiate"; | 269 std::string csv_auth_schemes = "basic,digest,ntlm,negotiate"; |
| 270 if (command_line.HasSwitch(switches::kAuthSchemes)) | 270 if (command_line.HasSwitch(switches::kAuthSchemes)) |
| 271 csv_auth_schemes = StringToLowerASCII( | 271 csv_auth_schemes = StringToLowerASCII( |
| 272 command_line.GetSwitchValueASCII(switches::kAuthSchemes)); | 272 command_line.GetSwitchValueASCII(switches::kAuthSchemes)); |
| 273 std::vector<std::string> supported_schemes; | 273 std::vector<std::string> supported_schemes; |
| 274 SplitString(csv_auth_schemes, ',', &supported_schemes); | 274 base::SplitString(csv_auth_schemes, ',', &supported_schemes); |
| 275 | 275 |
| 276 return net::HttpAuthHandlerRegistryFactory::Create( | 276 return net::HttpAuthHandlerRegistryFactory::Create( |
| 277 supported_schemes, | 277 supported_schemes, |
| 278 globals_->url_security_manager.get(), | 278 globals_->url_security_manager.get(), |
| 279 resolver, | 279 resolver, |
| 280 command_line.HasSwitch(switches::kDisableAuthNegotiateCnameLookup), | 280 command_line.HasSwitch(switches::kDisableAuthNegotiateCnameLookup), |
| 281 command_line.HasSwitch(switches::kEnableAuthNegotiatePort)); | 281 command_line.HasSwitch(switches::kEnableAuthNegotiatePort)); |
| 282 } | 282 } |
| 283 | 283 |
| 284 void IOThread::InitNetworkPredictorOnIOThread( | 284 void IOThread::InitNetworkPredictorOnIOThread( |
| (...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 321 net::HostCache* host_cache = | 321 net::HostCache* host_cache = |
| 322 globals_->host_resolver.get()->GetAsHostResolverImpl()->cache(); | 322 globals_->host_resolver.get()->GetAsHostResolverImpl()->cache(); |
| 323 if (host_cache) | 323 if (host_cache) |
| 324 host_cache->clear(); | 324 host_cache->clear(); |
| 325 } | 325 } |
| 326 // Clear all of the passively logged data. | 326 // Clear all of the passively logged data. |
| 327 // TODO(eroman): this is a bit heavy handed, really all we need to do is | 327 // TODO(eroman): this is a bit heavy handed, really all we need to do is |
| 328 // clear the data pertaining to off the record context. | 328 // clear the data pertaining to off the record context. |
| 329 globals_->net_log->passive_collector()->Clear(); | 329 globals_->net_log->passive_collector()->Clear(); |
| 330 } | 330 } |
| OLD | NEW |