| OLD | NEW |
| 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 "ios/crnet/crnet_environment.h" | 5 #include "ios/crnet/crnet_environment.h" |
| 6 | 6 |
| 7 #import <Foundation/Foundation.h> | 7 #import <Foundation/Foundation.h> |
| 8 | 8 |
| 9 #include <utility> | 9 #include <utility> |
| 10 | 10 |
| (...skipping 482 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 493 main_context_->http_user_agent_settings(); | 493 main_context_->http_user_agent_settings(); |
| 494 if (!user_agent_settings) { | 494 if (!user_agent_settings) { |
| 495 return nullptr; | 495 return nullptr; |
| 496 } | 496 } |
| 497 | 497 |
| 498 return user_agent_settings->GetUserAgent(); | 498 return user_agent_settings->GetUserAgent(); |
| 499 } | 499 } |
| 500 | 500 |
| 501 void CrNetEnvironment::ClearCache(ClearCacheCallback callback) { | 501 void CrNetEnvironment::ClearCache(ClearCacheCallback callback) { |
| 502 PostToNetworkThread( | 502 PostToNetworkThread( |
| 503 FROM_HERE, | 503 FROM_HERE, base::Bind(&net::ClearHttpCache, main_context_getter_, |
| 504 base::Bind(&net::ClearHttpCache, main_context_getter_, | 504 network_io_thread_->task_runner(), base::Time(), |
| 505 network_io_thread_->task_runner(), base::BindBlock(callback))); | 505 base::Time::Max(), base::BindBlock(callback))); |
| 506 } | 506 } |
| OLD | NEW |