Avoid interraction between pppd and routed, by trying to discover new

interfaces every time there is a new route, irrespective of timeout period.
This commit is contained in:
christos 1998-08-26 17:50:32 +00:00
parent 60f624ddb7
commit b2ae8c434d
2 changed files with 7 additions and 6 deletions

View File

@ -1,4 +1,4 @@
# $NetBSD: Makefile,v 1.18 1997/10/11 09:34:36 mycroft Exp $
# $NetBSD: Makefile,v 1.19 1998/08/26 17:50:32 christos Exp $
# from: @(#)Makefile 8.1 (Berkeley) 6/19/93
PROG= routed
@ -8,7 +8,7 @@ SUBDIR= rtquery
# By popular demand...
MLINKS= routed.8 rdisc.8
#COPTS=-g -DDEBUG -Wall
#COPTS+=-g -DDEBUG -Wall
.include <bsd.prog.mk>
.include <bsd.subdir.mk>

View File

@ -1,4 +1,4 @@
/* $NetBSD: if.c,v 1.14 1998/06/02 18:02:55 thorpej Exp $ */
/* $NetBSD: if.c,v 1.15 1998/08/26 17:50:33 christos Exp $ */
/*
* Copyright (c) 1983, 1993
@ -37,7 +37,7 @@
static char sccsid[] = "@(#)if.c 8.1 (Berkeley) 6/5/93";
#elif defined(__NetBSD__)
#include <sys/cdefs.h>
__RCSID("$NetBSD: if.c,v 1.14 1998/06/02 18:02:55 thorpej Exp $");
__RCSID("$NetBSD: if.c,v 1.15 1998/08/26 17:50:33 christos Exp $");
#endif
#include "defs.h"
@ -243,6 +243,7 @@ struct interface *
iflookup(naddr addr)
{
struct interface *ifp, *maybe;
int once = 0;
maybe = 0;
for (;;) {
@ -266,14 +267,14 @@ iflookup(naddr addr)
}
}
if (maybe != 0
|| IF_RESCAN_DELAY())
if (maybe != 0 || once)
return maybe;
/* If there is no known interface, maybe there is a
* new interface. So just once look for new interfaces.
*/
ifinit();
once = 1;
}
}