| 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/service/net/service_url_request_context.h" | 5 #include "chrome/service/net/service_url_request_context.h" |
| 6 | 6 |
| 7 #if defined(OS_POSIX) && !defined(OS_MACOSX) | 7 #if defined(OS_POSIX) && !defined(OS_MACOSX) |
| 8 #include <sys/utsname.h> | 8 #include <sys/utsname.h> |
| 9 #endif | 9 #endif |
| 10 | 10 |
| (...skipping 117 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 128 net::HttpNetworkLayer::CreateFactory(host_resolver_, | 128 net::HttpNetworkLayer::CreateFactory(host_resolver_, |
| 129 cert_verifier_, | 129 cert_verifier_, |
| 130 dnsrr_resolver_, | 130 dnsrr_resolver_, |
| 131 NULL /* dns_cert_checker */, | 131 NULL /* dns_cert_checker */, |
| 132 NULL /* ssl_host_info_factory */, | 132 NULL /* ssl_host_info_factory */, |
| 133 proxy_service_, | 133 proxy_service_, |
| 134 ssl_config_service_, | 134 ssl_config_service_, |
| 135 http_auth_handler_factory_, | 135 http_auth_handler_factory_, |
| 136 NULL /* network_delegate */, | 136 NULL /* network_delegate */, |
| 137 NULL /* net_log */), | 137 NULL /* net_log */), |
| 138 NULL /* net_log */, |
| 138 net::HttpCache::DefaultBackend::InMemory(0)); | 139 net::HttpCache::DefaultBackend::InMemory(0)); |
| 139 // In-memory cookie store. | 140 // In-memory cookie store. |
| 140 cookie_store_ = new net::CookieMonster(NULL, NULL); | 141 cookie_store_ = new net::CookieMonster(NULL, NULL); |
| 141 accept_language_ = "en-us,fr"; | 142 accept_language_ = "en-us,fr"; |
| 142 accept_charset_ = "iso-8859-1,*,utf-8"; | 143 accept_charset_ = "iso-8859-1,*,utf-8"; |
| 143 } | 144 } |
| 144 | 145 |
| 145 const std::string& ServiceURLRequestContext::GetUserAgent( | 146 const std::string& ServiceURLRequestContext::GetUserAgent( |
| 146 const GURL& url) const { | 147 const GURL& url) const { |
| 147 // If the user agent is set explicitly return that, otherwise call the | 148 // If the user agent is set explicitly return that, otherwise call the |
| (...skipping 23 matching lines...) Expand all Loading... |
| 171 url_request_context_ = new ServiceURLRequestContext(user_agent_); | 172 url_request_context_ = new ServiceURLRequestContext(user_agent_); |
| 172 return url_request_context_; | 173 return url_request_context_; |
| 173 } | 174 } |
| 174 | 175 |
| 175 scoped_refptr<base::MessageLoopProxy> | 176 scoped_refptr<base::MessageLoopProxy> |
| 176 ServiceURLRequestContextGetter::GetIOMessageLoopProxy() const { | 177 ServiceURLRequestContextGetter::GetIOMessageLoopProxy() const { |
| 177 return io_message_loop_proxy_; | 178 return io_message_loop_proxy_; |
| 178 } | 179 } |
| 179 | 180 |
| 180 ServiceURLRequestContextGetter::~ServiceURLRequestContextGetter() {} | 181 ServiceURLRequestContextGetter::~ServiceURLRequestContextGetter() {} |
| OLD | NEW |