diff
< if (pcnt > app_req.num_ports) {
---
> if (pcnt >= app_req.num_ports) {
