From owner-freebsd-hackers Tue Jul 27 21:22:22 1999 Delivered-To: freebsd-hackers@freebsd.org Received: from relay.nuxi.com (nuxi.cs.ucdavis.edu [169.237.7.38]) by hub.freebsd.org (Postfix) with ESMTP id 1530D14DC3 for ; Tue, 27 Jul 1999 21:22:18 -0700 (PDT) (envelope-from obrien@NUXI.com) Received: from dragon.nuxi.com (iras-1-74.ucdavis.edu [169.237.16.74]) by relay.nuxi.com (8.9.3/8.9.3) with ESMTP id VAA05095; Tue, 27 Jul 1999 21:21:30 -0700 (PDT) (envelope-from obrien@dragon.nuxi.com) Received: (from obrien@localhost) by dragon.nuxi.com (8.9.3/8.9.1) id VAA66779; Tue, 27 Jul 1999 21:21:29 -0700 (PDT) (envelope-from obrien) Date: Tue, 27 Jul 1999 21:21:26 -0700 From: "David O'Brien" To: Warner Losh Cc: hackers@FreeBSD.ORG Subject: Re: newsyslog owner.group -> owner:group Message-ID: <19990727212126.E66569@dragon.nuxi.com> Reply-To: obrien@NUXI.com References: <19755.933088309@axl.noc.iafrica.com> <199907280340.VAA68413@harmony.village.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Mailer: Mutt 0.95.3i In-Reply-To: <199907280340.VAA68413@harmony.village.org>; from Warner Losh on Tue, Jul 27, 1999 at 09:40:34PM -0600 X-Operating-System: FreeBSD 4.0-CURRENT Organization: The NUXI BSD group X-PGP-Fingerprint: B7 4D 3E E9 11 39 5F A3 90 76 5D 69 58 D9 98 7A X-Pgp-Keyid: 34F9F9D5 Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG > A better patch would check to see if the text to the right of the '.' > is a valid group... However, the above will still parse > > fred.jones:fred.jones > > in the most desirable way, so I suppose the validity checking is > overkill. This is what I plan to commit (w/in minutes): - if ((group = strchr(q, ':')) != NULL) { + if ((group = strchr(q, ':')) != NULL || + (group = strrchr(q, '.')) != NULL) { It the becomes [almost totally] non-ambigitous (since the separator is required) and allows "david.obrien.staff". In my mind more people use dots in usernames than group names. Anyay, it is documented to use :, and I am just trying to be "liberal in what is accepted" (w/o obfuscating the code). -- -- David (obrien@NUXI.com -or- obrien@FreeBSD.org) To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message