From: Mike Karels Date: Fri, 21 Dec 1984 10:05:19 +0000 (-0800) Subject: reinstall point-to-point interface when it reappears X-Git-Tag: BSD-4_3-Snapshot-Development~9146 X-Git-Url: https://git.subgeniuskitty.com/unix-history/.git/commitdiff_plain/f1e15e15554cd23f22eb78d0cdd0f1dea9c50470 reinstall point-to-point interface when it reappears SCCS-vsn: sbin/routed/input.c 4.10 --- diff --git a/usr/src/sbin/routed/input.c b/usr/src/sbin/routed/input.c index 8419fd1f2c..e1f837681e 100644 --- a/usr/src/sbin/routed/input.c +++ b/usr/src/sbin/routed/input.c @@ -1,5 +1,5 @@ #ifndef lint -static char sccsid[] = "@(#)input.c 4.9 (Berkeley) %G%"; +static char sccsid[] = "@(#)input.c 4.10 (Berkeley) %G%"; #endif /* @@ -94,9 +94,15 @@ rip_input(from, size) rt->rt_timer = 0; return; } - /* update timer for interface on which the packet arrived */ + /* + * Update timer for interface on which the packet arrived. + * If from other end of a point-to-point link that isn't + * in the routing tables, (re-)add the route. + */ if ((rt = rtfind(from)) && (rt->rt_state & RTS_INTERFACE)) rt->rt_timer = 0; + else if (ifp = if_ifwithdstaddr(from)) + addrouteforif(ifp); size -= 4 * sizeof (char); n = msg->rip_nets; for (; size > 0; size -= sizeof (struct netinfo), n++) {