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

Side by Side Diff: chrome/browser/policy/configuration_policy_pref_store.cc

Issue 6871019: Enable (optional) blocking of webrequests in case a PAC script cannot be fetched or is invalid. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Addressed comments Created 9 years, 7 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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/policy/configuration_policy_pref_store.h" 5 #include "chrome/browser/policy/configuration_policy_pref_store.h"
6 6
7 #include <map> 7 #include <map>
8 #include <set> 8 #include <set>
9 #include <string> 9 #include <string>
10 #include <vector> 10 #include <vector>
(...skipping 674 matching lines...) Expand 10 before | Expand all | Expand 10 after
685 case ProxyPrefs::MODE_DIRECT: 685 case ProxyPrefs::MODE_DIRECT:
686 prefs_.SetValue(prefs::kProxy, ProxyConfigDictionary::CreateDirect()); 686 prefs_.SetValue(prefs::kProxy, ProxyConfigDictionary::CreateDirect());
687 break; 687 break;
688 case ProxyPrefs::MODE_AUTO_DETECT: 688 case ProxyPrefs::MODE_AUTO_DETECT:
689 prefs_.SetValue(prefs::kProxy, ProxyConfigDictionary::CreateAutoDetect()); 689 prefs_.SetValue(prefs::kProxy, ProxyConfigDictionary::CreateAutoDetect());
690 break; 690 break;
691 case ProxyPrefs::MODE_PAC_SCRIPT: { 691 case ProxyPrefs::MODE_PAC_SCRIPT: {
692 std::string pac_url; 692 std::string pac_url;
693 proxy_policies_[kPolicyProxyPacUrl]->GetAsString(&pac_url); 693 proxy_policies_[kPolicyProxyPacUrl]->GetAsString(&pac_url);
694 prefs_.SetValue(prefs::kProxy, 694 prefs_.SetValue(prefs::kProxy,
695 ProxyConfigDictionary::CreatePacScript(pac_url)); 695 ProxyConfigDictionary::CreatePacScript(pac_url, false));
696 break; 696 break;
697 } 697 }
698 case ProxyPrefs::MODE_FIXED_SERVERS: { 698 case ProxyPrefs::MODE_FIXED_SERVERS: {
699 std::string proxy_server; 699 std::string proxy_server;
700 proxy_policies_[kPolicyProxyServer]->GetAsString(&proxy_server); 700 proxy_policies_[kPolicyProxyServer]->GetAsString(&proxy_server);
701 std::string bypass_list; 701 std::string bypass_list;
702 if (HasProxyPolicy(kPolicyProxyBypassList)) 702 if (HasProxyPolicy(kPolicyProxyBypassList))
703 proxy_policies_[kPolicyProxyBypassList]->GetAsString(&bypass_list); 703 proxy_policies_[kPolicyProxyBypassList]->GetAsString(&bypass_list);
704 prefs_.SetValue(prefs::kProxy, 704 prefs_.SetValue(prefs::kProxy,
705 ProxyConfigDictionary::CreateFixedServers(proxy_server, 705 ProxyConfigDictionary::CreateFixedServers(proxy_server,
(...skipping 312 matching lines...) Expand 10 before | Expand all | Expand 10 after
1018 // Update the initialization flag. 1018 // Update the initialization flag.
1019 if (!initialization_complete_ && 1019 if (!initialization_complete_ &&
1020 provider_->IsInitializationComplete()) { 1020 provider_->IsInitializationComplete()) {
1021 initialization_complete_ = true; 1021 initialization_complete_ = true;
1022 FOR_EACH_OBSERVER(PrefStore::Observer, observers_, 1022 FOR_EACH_OBSERVER(PrefStore::Observer, observers_,
1023 OnInitializationCompleted()); 1023 OnInitializationCompleted());
1024 } 1024 }
1025 } 1025 }
1026 1026
1027 } // namespace policy 1027 } // namespace policy
OLDNEW
« no previous file with comments | « chrome/browser/net/pref_proxy_config_service_unittest.cc ('k') | chrome/browser/prefs/command_line_pref_store.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698