Commit dce724f6 authored by Juliusz Chroboczek's avatar Juliusz Chroboczek

Only uninstall necessary xroutes when uninstalling a route.

parent 3709c80a
......@@ -175,7 +175,9 @@ uninstall_route(struct route *route)
return;
for(i = 0; i < numxroutes; i++) {
if(xroutes[i].installed && xroutes[i].nexthop == route->nexthop)
if(xroutes[i].installed &&
xroutes[i].gateway == route->dest &&
xroutes[i].nexthop == route->nexthop)
uninstall_xroute(&xroutes[i]);
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment