Subject: bin/9431: routed does not substract maxroutes when add fails
To: None <gnats-bugs@gnats.netbsd.org>
From: Jarkko Torppa <torppa@staff.megabaud.fi>
List: netbsd-bugs
Date: 02/16/2000 04:39:39
>Number: 9431
>Category: bin
>Synopsis: routed does not substract maxroutes when add fails
>Confidential: yes
>Severity: serious
>Priority: medium
>Responsible: bin-bug-people (Utility Bug People)
>State: open
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Wed Feb 16 04:39:00 2000
>Last-Modified:
>Originator: Jarkko Torppa
>Organization:
Jarkko Torppa torppa@staff.megabaud.fi
>Release: 1.4.2_ALPHA and current
>Environment:
System: NetBSD polykoira.megabaud.fi 1.4.1 NetBSD 1.4.1 (POLY) #2: Tue Sep 14 23:05:00 EEST 1999 root@:/usr/src/sys/arch/i386/compile/POLY i386
>Description:
when route addition fails routed does not substract total_routes,
this is another part of the same bug that was fixed by 9390. But I
have no idea if I can add to closed bug.
>How-To-Repeat:
Put "chatty" rip on network and wait for a "while"
>Fix:
one possible fix below
/* $NetBSD: table.c,v 1.12 2000/02/11 18:39:02 christos Exp $ */
--- table.c.orig Wed Feb 16 14:28:55 2000
+++ table.c Wed Feb 16 14:32:38 2000
@@ -1721,8 +1721,6 @@
rt->rt_poison_metric = HOPCNT_INFINITY;
rt->rt_seqno = update_seqno;
- if (++total_routes == MAX_ROUTES)
- msglog("have maximum (%d) routes", total_routes);
if (TRACEACTIONS)
trace_add_del("Add", rt);
@@ -1734,7 +1732,9 @@
msglog("rnh_addaddr() failed for %s mask=%#lx",
naddr_ntoa(dst), (u_long)mask);
free(rt);
- }
+ } else
+ if (++total_routes == MAX_ROUTES)
+ msglog("have maximum (%d) routes", total_routes);
}
>Audit-Trail:
>Unformatted:
no
routed does not substract maxroutes when add fails
serious
medium