The return code of dpif_netlink_port_query__() was not being checked.
Fixes: da467899ab6e ("Windows: Add internal switch port per OVS bridge")
Signed-off-by: Eric Garver <e@erig.me>
Acked-by: Alin Gabriel Serdean <aserdean@cloudbasesolutions.com>
Signed-off-by: Joe Stringer <joe@ovn.org>
vport.port_no = port_no;
#ifdef _WIN32
struct dpif_port temp_dpif_port;
- dpif_netlink_port_query__(dpif, port_no, NULL, &temp_dpif_port);
+
+ error = dpif_netlink_port_query__(dpif, port_no, NULL, &temp_dpif_port);
+ if (error) {
+ return error;
+ }
if (!strcmp(temp_dpif_port.type, "internal")) {
if (!delete_wmi_port(temp_dpif_port.name)){
VLOG_ERR("Could not delete wmi port with name: %s",