mirror of https://github.com/apache/activemq.git
resolve: https://issues.apache.org/activemq/browse/AMQ-2776 - apply variant of patch. also related to https://issues.apache.org/activemq/browse/AMQ-2771, avoid unnecessary local host name resolution
git-svn-id: https://svn.apache.org/repos/asf/activemq/trunk@983565 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
7f7a95b457
commit
670a9c4c56
|
@ -399,9 +399,9 @@ public class TcpTransport extends TransportThreadSupport implements Transport, S
|
|||
// Implementation methods
|
||||
// -------------------------------------------------------------------------
|
||||
protected String resolveHostName(String host) throws UnknownHostException {
|
||||
String localName = InetAddress.getLocalHost().getHostName();
|
||||
if (localName != null && isUseLocalHost()) {
|
||||
if (localName.equals(host)) {
|
||||
if (isUseLocalHost()) {
|
||||
String localName = InetAddress.getLocalHost().getHostName();
|
||||
if (localName != null && localName.equals(host)) {
|
||||
return "localhost";
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue