mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-12 21:05:36 +00:00
fixes bug 86846 "PAC: Cannot display alert() in autproxy config file" r=biesi sr=bzbarsky
This commit is contained in:
parent
f3ef614ee5
commit
164a11fd94
@ -128,6 +128,7 @@ nsProxyAutoConfig.prototype = {
|
||||
ProxySandBox.myIP = "127.0.0.1";
|
||||
}
|
||||
ProxySandBox.dnsResolve = dnsResolve;
|
||||
ProxySandBox.alert = proxyAlert;
|
||||
LocalFindProxyForURL=ProxySandBox.FindProxyForURL;
|
||||
this.done = true;
|
||||
},
|
||||
@ -138,6 +139,16 @@ nsProxyAutoConfig.prototype = {
|
||||
}
|
||||
}
|
||||
|
||||
function proxyAlert(msg) {
|
||||
try {
|
||||
var cns = Components.classes["@mozilla.org/consoleservice;1"]
|
||||
.getService(Components.interfaces.nsIConsoleService);
|
||||
cns.logStringMessage("PAC-alert: "+msg);
|
||||
} catch (e) {
|
||||
dump("PAC: proxyAlert ERROR: "+e+"\n");
|
||||
}
|
||||
}
|
||||
|
||||
// Synchronous calls to nsDNSService::Resolve ignore the cache! (bug 97097)
|
||||
// Keep a simple one of our own.
|
||||
var dnsResolveCachedHost = null;
|
||||
|
Loading…
Reference in New Issue
Block a user