Do not return failure to parse a route if device has been removed before we are
able to parse the route. That prevents "received bad netlink message" warnings
on the log.

This can be reproduced by simply removing interfaces.

Signed-off-by: Thadeu Lima de Souza Cascardo <[email protected]>
---
 lib/route-table.c | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/lib/route-table.c b/lib/route-table.c
index 2d095dc..d837d98 100644
--- a/lib/route-table.c
+++ b/lib/route-table.c
@@ -252,7 +252,11 @@ route_table_parse(struct ofpbuf *buf, struct 
route_table_msg *change)
 
                 VLOG_DBG_RL(&rl, "Could not find interface name[%u]: %s",
                             rta_oif, ovs_strerror(error));
-                return false;
+                if (error == ENXIO) {
+                    change->relevant = false;
+                } else {
+                    return false;
+                }
             }
         }
 
-- 
2.5.5

_______________________________________________
dev mailing list
[email protected]
http://openvswitch.org/mailman/listinfo/dev

Reply via email to