freebsd-dev/usr.sbin/newsyslog
gad 7edd4b5ef8 When checking the 'user:group' field in newsyslog.conf, freebsd's source
was mistakenly calling the standard isnumber() function to find out if
the given 'user' or 'group' were all numeric.  This meant that only the
first character of the fields were actually checked, so a username of
(say) '3com' would look like a number, and thus get mapped to uid=3 (bin)
instead of username=3com.

This bug was introduced back in freebsd's v1.1.  That initial import
almost matches netbsd's v1.9, except that an internal isnumber()
routine was removed in favor of the standard library version.  The thing
is, that internal routine was checking the entire string, and not just
the first digit.  In OpenBSD, isnumber() was eventually renamed to
isnumberstr() to make the distinction more obvious, and I'm going to
follow that lead.

I believe this also happens to remove the last references to isnumber()
in the entire freebsd base system.

Obtained from:	OpenBSD, by a long circuitous route
MFC after:	5 days
2003-08-19 03:53:03 +00:00
..
Makefile Backout unapproved WARNS level change occasionally slipped into previous 2002-12-11 01:21:57 +00:00
newsyslog.8 Add a -C (create) option for newsyslog, and a 'C' flag for entries in the 2003-04-27 23:37:31 +00:00
newsyslog.c When checking the 'user:group' field in newsyslog.conf, freebsd's source 2003-08-19 03:53:03 +00:00
pathnames.h Add the ability to Bzip2 your logs. 2001-07-30 15:17:17 +00:00