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

Unified Diff: chrome/browser/net/chrome_network_delegate.cc

Issue 2654993002: Remove --allow-file-access and accompanying logic (Closed)
Patch Set: Created 3 years, 11 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/browser/net/chrome_network_delegate.h ('k') | chrome/common/chrome_switches.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/net/chrome_network_delegate.cc
diff --git a/chrome/browser/net/chrome_network_delegate.cc b/chrome/browser/net/chrome_network_delegate.cc
index 3b866102845df0058f5440290464d90e86e9f2a9..0a2b6b5c0e6cedb37a8f3da56d420fc28ef0e6fc 100644
--- a/chrome/browser/net/chrome_network_delegate.cc
+++ b/chrome/browser/net/chrome_network_delegate.cc
@@ -81,14 +81,6 @@ using content::BrowserThread;
using content::RenderViewHost;
using content::ResourceRequestInfo;
-// By default we don't allow access to all file:// urls on ChromeOS and
-// Android.
-#if defined(OS_CHROMEOS) || defined(OS_ANDROID)
-bool ChromeNetworkDelegate::g_allow_file_access_ = false;
-#else
-bool ChromeNetworkDelegate::g_allow_file_access_ = true;
-#endif
-
namespace {
const char kDNTHeader[] = "DNT";
@@ -220,11 +212,6 @@ void ChromeNetworkDelegate::InitializePrefsOnUIThread(
}
}
-// static
-void ChromeNetworkDelegate::AllowAccessToAllFiles() {
- g_allow_file_access_ = true;
-}
-
int ChromeNetworkDelegate::OnBeforeURLRequest(
net::URLRequest* request,
const net::CompletionCallback& callback,
@@ -464,9 +451,6 @@ bool ChromeNetworkDelegate::OnCanSetCookie(const net::URLRequest& request,
bool ChromeNetworkDelegate::OnCanAccessFile(const net::URLRequest& request,
const base::FilePath& path) const {
- if (g_allow_file_access_)
- return true;
-
#if !defined(OS_CHROMEOS) && !defined(OS_ANDROID)
return true;
#else
« no previous file with comments | « chrome/browser/net/chrome_network_delegate.h ('k') | chrome/common/chrome_switches.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698