diff -u xulrunner-1.9-1.9~b5+nobinonly/debian/patches/series xulrunner-1.9-1.9~b5+nobinonly/debian/patches/series --- xulrunner-1.9-1.9~b5+nobinonly/debian/patches/series +++ xulrunner-1.9-1.9~b5+nobinonly/debian/patches/series @@ -22,0 +23 @@ +bz422172_att318657_fix_proxyautoconfig_reload.patch diff -u xulrunner-1.9-1.9~b5+nobinonly/debian/changelog xulrunner-1.9-1.9~b5+nobinonly/debian/changelog --- xulrunner-1.9-1.9~b5+nobinonly/debian/changelog +++ xulrunner-1.9-1.9~b5+nobinonly/debian/changelog @@ -1,3 +1,12 @@ +xulrunner-1.9 (1.9~b5+nobinonly-0ubuntu4) intrepid; urgency=low + + * fix the reload of the proxy automatic configuration (PAC) (LP: #225520). + Patch submitted upstream in bugzilla 422162. + - add debian/patches/bz422172_att318657_fix_proxyautoconfig_reload.patch + - update debian/patches/series + + -- Hugues Fournier Fri, 02 May 2008 05:25:25 +0200 + xulrunner-1.9 (1.9~b5+nobinonly-0ubuntu3) hardy; urgency=low * j2re1.4 is the package that ships the plugin, not the mozilla-plugin only in patch2: unchanged: --- xulrunner-1.9-1.9~b5+nobinonly.orig/debian/patches/bz422172_att318657_fix_proxyautoconfig_reload.patch +++ xulrunner-1.9-1.9~b5+nobinonly/debian/patches/bz422172_att318657_fix_proxyautoconfig_reload.patch @@ -0,0 +1,124 @@ +Index: netwerk/base/src/nsProtocolProxyService.cpp +=================================================================== +RCS file: /cvsroot/mozilla/netwerk/base/src/nsProtocolProxyService.cpp,v +retrieving revision 1.81 +diff -u -8 -p -r1.81 nsProtocolProxyService.cpp +--- a/netwerk/base/src/nsProtocolProxyService.cpp 18 Apr 2008 02:49:40 -0000 1.81 ++++ b/netwerk/base/src/nsProtocolProxyService.cpp 30 Apr 2008 18:25:16 -0000 +@@ -493,17 +493,17 @@ nsProtocolProxyService::PrefsChanged(nsI + // substitution of the first component, if that proves to help + // compatibility. + tempString.AssignLiteral(WPAD_URL); + } else if (mSystemProxySettings) { + // Get System Proxy settings if available + mSystemProxySettings->GetPACURI(tempString); + } + if (!tempString.IsEmpty()) +- ConfigureFromPAC(tempString); ++ ConfigureFromPAC(tempString, PR_FALSE); + } + } + + PRBool + nsProtocolProxyService::CanUseProxy(nsIURI *aURI, PRInt32 defaultPort) + { + if (mHostFiltersArray.Count() == 0) + return PR_TRUE; +@@ -753,30 +753,31 @@ nsProtocolProxyService::IsProxyDisabled( + mFailedProxies.Remove(key); + return PR_FALSE; + } + + return PR_TRUE; + } + + nsresult +-nsProtocolProxyService::ConfigureFromPAC(const nsCString &spec) ++nsProtocolProxyService::ConfigureFromPAC(const nsCString &spec, ++ PRBool forceReload) + { + if (!mPACMan) { + mPACMan = new nsPACMan(); + if (!mPACMan) + return NS_ERROR_OUT_OF_MEMORY; + } + + nsCOMPtr pacURI; + nsresult rv = NS_NewURI(getter_AddRefs(pacURI), spec); + if (NS_FAILED(rv)) + return rv; + +- if (mPACMan->IsPACURI(pacURI)) ++ if (mPACMan->IsPACURI(pacURI) && !forceReload) + return NS_OK; + + mFailedProxies.Clear(); + + return mPACMan->LoadPACFromURI(pacURI); + } + + void +@@ -821,17 +822,17 @@ nsProtocolProxyService::ReloadPAC() + + nsXPIDLCString pacSpec; + if (type == eProxyConfig_PAC) + prefs->GetCharPref(PROXY_PREF("autoconfig_url"), getter_Copies(pacSpec)); + else if (type == eProxyConfig_WPAD) + pacSpec.AssignLiteral(WPAD_URL); + + if (!pacSpec.IsEmpty()) +- ConfigureFromPAC(pacSpec); ++ ConfigureFromPAC(pacSpec, PR_TRUE); + return NS_OK; + } + + // nsIProtocolProxyService + NS_IMETHODIMP + nsProtocolProxyService::Resolve(nsIURI *uri, PRUint32 flags, + nsIProxyInfo **result) + { +@@ -1251,17 +1252,17 @@ nsProtocolProxyService::Resolve_Internal + return NS_OK; // Can't proxy this (filters may not override) + + if (mSystemProxySettings) { + nsCAutoString PACURI; + if (NS_SUCCEEDED(mSystemProxySettings->GetPACURI(PACURI)) && + !PACURI.IsEmpty()) { + // Switch to new PAC file if that setting has changed. If the setting + // hasn't changed, ConfigureFromPAC will exit early. +- nsresult rv = ConfigureFromPAC(PACURI); ++ nsresult rv = ConfigureFromPAC(PACURI, PR_FALSE); + if (NS_FAILED(rv)) + return rv; + } else { + nsCAutoString proxy; + nsresult rv = mSystemProxySettings->GetProxyForURI(uri, proxy); + if (NS_SUCCEEDED(rv)) { + ProcessPACString(proxy, result); + return NS_OK; +Index: netwerk/base/src/nsProtocolProxyService.h +=================================================================== +RCS file: /cvsroot/mozilla/netwerk/base/src/nsProtocolProxyService.h,v +retrieving revision 1.33 +diff -u -8 -p -r1.33 nsProtocolProxyService.h +--- a/netwerk/base/src/nsProtocolProxyService.h 29 Jan 2008 18:38:15 -0000 1.33 ++++ b/netwerk/base/src/nsProtocolProxyService.h 30 Apr 2008 18:25:16 -0000 +@@ -109,17 +109,17 @@ protected: + nsProxyInfo **result); + + /** + * Load the specified PAC file. + * + * @param pacURI + * The URI spec of the PAC file to load. + */ +- NS_HIDDEN_(nsresult) ConfigureFromPAC(const nsCString &pacURI); ++ NS_HIDDEN_(nsresult) ConfigureFromPAC(const nsCString &pacURI, PRBool forceReload); + + /** + * This method builds a list of nsProxyInfo objects from the given PAC- + * style string. + * + * @param pacString + * The PAC-style proxy string to parse. This may be empty. + * @param result