Fix: resolve NPE by obtaining networkId from subnet instead of port

Change-Id: Ib49a8627e601bc893062069daf6f266fcc8e8460
This commit is contained in:
Jian Li 2018-04-12 09:48:50 +09:00
parent 700648c993
commit bb4f541bb2

View File

@ -330,7 +330,8 @@ public final class OpenstackSwitchingArpHandler {
return false;
}
Network network = osNetworkService.network(event.port().getNetworkId());
Network network = osNetworkService.network(osSubnet.getNetworkId());
if (network == null) {
log.warn("Network is not specified.");
return false;