https://issues.apache.org/jira/browse/AMQ-6297 - null check for case where interface has no bindings

This commit is contained in:
gtully 2016-05-20 14:54:04 +01:00
parent 991d69f387
commit daf7e85e68
1 changed files with 1 additions and 1 deletions

View File

@ -348,7 +348,7 @@ public class MulticastDiscoveryAgent implements DiscoveryAgent, Runnable {
if (ni.supportsMulticast() if (ni.supportsMulticast()
&& ni.isUp()) { && ni.isUp()) {
for (InterfaceAddress ia : ni.getInterfaceAddresses()) { for (InterfaceAddress ia : ni.getInterfaceAddresses()) {
if (ia.getAddress() instanceof java.net.Inet4Address if (ia != null && ia.getAddress() instanceof java.net.Inet4Address
&& !ia.getAddress().isLoopbackAddress() && !ia.getAddress().isLoopbackAddress()
&& !ni.getDisplayName().startsWith("vnic")) { && !ni.getDisplayName().startsWith("vnic")) {
possibles.add(ni); possibles.add(ni);