mirror of
https://github.com/opennetworkinglab/onos.git
synced 2025-12-18 07:41:47 +01:00
Replace non-looping while with an if
Change-Id: I1e05b4b9c311f5ded063663f2113e0b8a1bb7e85
This commit is contained in:
parent
5881be845d
commit
b1f4e0f2f9
@ -342,7 +342,7 @@ public class OvsdbControllerImpl implements OvsdbController {
|
|||||||
OvsdbSet ofPortSet = (OvsdbSet) intf.getOpenFlowPortColumn().data();
|
OvsdbSet ofPortSet = (OvsdbSet) intf.getOpenFlowPortColumn().data();
|
||||||
@SuppressWarnings("unchecked")
|
@SuppressWarnings("unchecked")
|
||||||
Set<Integer> ofPorts = ofPortSet.set();
|
Set<Integer> ofPorts = ofPortSet.set();
|
||||||
while (ofPorts == null || ofPorts.isEmpty()) {
|
if (ofPorts == null || ofPorts.isEmpty()) {
|
||||||
log.debug("The ofport is null in {}", intf.getName());
|
log.debug("The ofport is null in {}", intf.getName());
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user