Fixes changing the default subnet route after removing an ip address. See: http://www.netbsd.org/cgi-bin/query-pr-single.pl?number=40133 and http://mail-index.netbsd.org/tech-net/2008/12/03/msg000896.html Thanks to Roy Marples. --- sys/netinet/in.c.orig +++ sys/netinet/in.c @@ -858,6 +858,12 @@ error = rtinit(&target->ia_ifa, (int)RTM_ADD, flags); if (!error) target->ia_flags |= IFA_ROUTE; + else if (error == EEXIST) { + /* + * the fact that the route already exists is not an error. + */ + error = 0; + } return error; }