Date: 1 Dec 2006 08:16:22 -0000 From: Niki Denev <niki@totalterror.net> To: FreeBSD-gnats-submit@FreeBSD.org Subject: misc/106112: libalias treats every line in /etc/libalias.conf as loadable module (even the comments) Message-ID: <20061201081622.30297.qmail@tormentor.totalterror.net> Resent-Message-ID: <200612010820.kB18KRwo014960@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
>Number: 106112 >Category: misc >Synopsis: libalias treats every line in /etc/libalias.conf as loadable module (even the comments) >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Fri Dec 01 08:20:22 GMT 2006 >Closed-Date: >Last-Modified: >Originator: Niki Denev <niki@totalterror.net>, <nike_d@cytexbg.com> >Release: FreeBSD 7.0-CURRENT i386 >Organization: >Environment: System: FreeBSD phobos.totalterror.net 7.0-CURRENT FreeBSD 7.0-CURRENT #13: Wed Nov 15 07:10:16 EET 2006 nike_d@phobos.totalterror.net:/usr/src/sys/i386/compile/PHOBOS i386 >Description: The new libalias treats every line in /etc/libalias.conf as loadable module (even the comments), and tries to load them one by one. >How-To-Repeat: Starting 'ppp' for example will try to load the modules defined in /etc/libalias.conf, and it will complain about problems loading the first line in the file, which is the comment line holding the file $FreeBSD Id. >Fix: A probably not very complete fix because it will skip only lines starting with '#', but will fail to detect those with leading whitespace. Anyway here it is : --- /usr/src/sys/netinet/libalias/alias.c.orig Wed Nov 22 21:35:58 2006 +++ /usr/src/sys/netinet/libalias/alias.c Wed Nov 22 21:35:20 2006 @@ -1506,6 +1506,7 @@ break; len = strlen(buf); if (len > 1) { + if (buf[0] == '#') continue; buf[len - 1] = '\0'; printf("Loading %s\n", buf); LibAliasLoadModule(buf); >Release-Note: >Audit-Trail: >Unformatted:
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20061201081622.30297.qmail>