Replace non-looping while with an if

Change-Id: I1e05b4b9c311f5ded063663f2113e0b8a1bb7e85
This commit is contained in:
Jon Hall 2017-02-22 13:36:16 -08:00 committed by Yuta HIGUCHI
parent 5881be845d
commit b1f4e0f2f9

View File

@ -342,7 +342,7 @@ public class OvsdbControllerImpl implements OvsdbController {
OvsdbSet ofPortSet = (OvsdbSet) intf.getOpenFlowPortColumn().data();
@SuppressWarnings("unchecked")
Set<Integer> ofPorts = ofPortSet.set();
while (ofPorts == null || ofPorts.isEmpty()) {
if (ofPorts == null || ofPorts.isEmpty()) {
log.debug("The ofport is null in {}", intf.getName());
return -1;
}