Add myIpAddress() to PAC proxy environment.
Also fixed issue with dnsResolve() in same.
This commit is contained in:
@@ -1,5 +1,10 @@
|
||||
# Getdown Releases
|
||||
|
||||
## 1.8.6 - Unreleased
|
||||
|
||||
* Fixed issues with PAC proxy support: added `myIpAddress()`, fixed `dnsResolve()`, fixed crash
|
||||
when detecting PAC proxy.
|
||||
|
||||
## 1.8.5 - May 29, 2019
|
||||
|
||||
* Fixed issues with proxy information not getting properly passed through to app.
|
||||
|
||||
@@ -237,7 +237,14 @@ public final class ProxyUtil {
|
||||
public static class Resolver {
|
||||
public String dnsResolve (String host) {
|
||||
try {
|
||||
return InetAddress.getByName(host).toString();
|
||||
return InetAddress.getByName(host).getHostAddress();
|
||||
} catch (UnknownHostException uhe) {
|
||||
return null;
|
||||
}
|
||||
}
|
||||
public String myIpAddress () {
|
||||
try {
|
||||
return InetAddress.getLocalHost().getHostAddress();
|
||||
} catch (UnknownHostException uhe) {
|
||||
return null;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user