Subject: bin/11823: pppd; netmask option doesn't actually set netmask
To: None <>
From: None <>
List: netbsd-bugs
Date: 12/27/2000 03:39:20
>Number:         11823
>Category:       bin
>Synopsis:       pppd; netmask option doesn't actually set netmask
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    bin-bug-people
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Wed Dec 27 03:39:00 PST 2000
>Originator:     enami tsugutomo
>Release:        NetBSD-current 1997 June 29
System: NetBSD 1.2G NetBSD 1.2G (PAVLOV) #299: Sat Jun 28 11:55:32 JST 1997 i386

	netmask option of pppd doesn't actually set netmask.

	invoke pppd with netmask option other than default mask,
	and see actual netmask by ifconfig ppp?.

	or, inspect the source code.  there is no place where
	some value is assigned to the global variable `netmask'
	other than initalization.

	Here is my fix:

Index: options.c
RCS file: /a/cvsroot/NetBSD/src/usr.sbin/pppd/pppd/options.c,v
retrieving revision
diff -u -r1.1.1.2 options.c
--- options.c	1997/05/18 13:38:58
+++ options.c	1997/06/30 12:26:24
@@ -1835,6 +1835,7 @@
 	return 0;
+    netmask = mask;
     return (1);