Bug 1337336 - Fix ReloadPAC() for the PROXYCONFIG_SYSTEM case. r=bagder
authorJun <zaczh@hotmail.com>
Wed, 15 Mar 2017 03:21:00 -0400
changeset 347931 801d9e9ec6cd
parent 347930 91daf808bfcb
child 347932 dd0376458483
push id31508
push usercbook@mozilla.com
push dateThu, 16 Mar 2017 14:36:04 +0000
treeherdermozilla-central@468dde251604 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersbagder
bugs1337336
milestone55.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1337336 - Fix ReloadPAC() for the PROXYCONFIG_SYSTEM case. r=bagder
netwerk/base/nsProtocolProxyService.cpp
--- a/netwerk/base/nsProtocolProxyService.cpp
+++ b/netwerk/base/nsProtocolProxyService.cpp
@@ -1108,16 +1108,21 @@ nsProtocolProxyService::ReloadPAC()
     if (NS_FAILED(rv))
         return NS_OK;
 
     nsXPIDLCString pacSpec;
     if (type == PROXYCONFIG_PAC)
         prefs->GetCharPref(PROXY_PREF("autoconfig_url"), getter_Copies(pacSpec));
     else if (type == PROXYCONFIG_WPAD)
         pacSpec.AssignLiteral(WPAD_URL);
+    else if (type == PROXYCONFIG_SYSTEM) {
+        if (mSystemProxySettings)
+            mSystemProxySettings->GetPACURI(pacSpec);
+        ResetPACThread();
+    }
 
     if (!pacSpec.IsEmpty())
         ConfigureFromPAC(pacSpec, true);
     return NS_OK;
 }
 
 // When sync interface is removed this can go away too
 // The nsPACManCallback portion of this implementation should be run