Chromium Code Reviews| Index: net/url_request/url_request.cc |
| diff --git a/net/url_request/url_request.cc b/net/url_request/url_request.cc |
| index 8597917f0cbf49c84b3bdae3a7bebacbc264f1e0..ead9907c4f67465c5eb0f281cd6cff323d8d9951 100644 |
| --- a/net/url_request/url_request.cc |
| +++ b/net/url_request/url_request.cc |
| @@ -337,13 +337,16 @@ bool URLRequest::IsHandledURL(const GURL& url) { |
| } |
| // static |
| -void URLRequest::AllowFileAccess() { |
| - URLRequestJobManager::GetInstance()->set_enable_file_access(true); |
| +void URLRequest::AllowAccessToAllFiles() { |
| + URLRequestJobManager::GetInstance()->set_file_access_allowed(true); |
| } |
| -// static |
| -bool URLRequest::IsFileAccessAllowed() { |
| - return URLRequestJobManager::GetInstance()->enable_file_access(); |
| +bool URLRequest::IsFileAccessAllowed(const FilePath& path) { |
| + if (URLRequestJobManager::GetInstance()->file_access_allowed()) |
|
willchan no longer on Chromium
2012/04/19 21:12:24
From what I can tell, all this code was added pure
Greg Spencer (Chromium)
2012/04/20 00:05:54
Yeah, you're right. I've moved almost all of it e
willchan no longer on Chromium
2012/04/20 00:14:03
Can you get rid of that and just set a NetworkDele
Greg Spencer (Chromium)
2012/04/20 19:21:28
Duh, that would be better. :-) Done.
|
| + return true; |
| + if (context_ && context_->network_delegate()) |
| + return context_->network_delegate()->NotifyFileAccessRequested(this, path); |
| + return false; |
| } |
| void URLRequest::set_first_party_for_cookies( |