From owner-freebsd-bugs@FreeBSD.ORG Fri Dec 1 08:20:39 2006 Return-Path: X-Original-To: freebsd-bugs@hub.freebsd.org Delivered-To: freebsd-bugs@hub.freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 4932F16A492 for ; Fri, 1 Dec 2006 08:20:39 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [69.147.83.40]) by mx1.FreeBSD.org (Postfix) with ESMTP id 7AD8543CC1 for ; Fri, 1 Dec 2006 08:20:15 +0000 (GMT) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (gnats@localhost [127.0.0.1]) by freefall.freebsd.org (8.13.4/8.13.4) with ESMTP id kB18KRbX014961 for ; Fri, 1 Dec 2006 08:20:27 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.13.4/8.13.4/Submit) id kB18KRwo014960; Fri, 1 Dec 2006 08:20:27 GMT (envelope-from gnats) Resent-Date: Fri, 1 Dec 2006 08:20:27 GMT Resent-Message-Id: <200612010820.kB18KRwo014960@freefall.freebsd.org> Resent-From: FreeBSD-gnats-submit@FreeBSD.org (GNATS Filer) Resent-To: freebsd-bugs@FreeBSD.org Resent-Reply-To: FreeBSD-gnats-submit@FreeBSD.org, Niki Denev Received: from mx1.FreeBSD.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 313BE16A403 for ; Fri, 1 Dec 2006 08:16:26 +0000 (UTC) (envelope-from nike_d@tormentor.totalterror.net) Received: from sellinet.net (galileo.sellinet.net [82.199.192.2]) by mx1.FreeBSD.org (Postfix) with SMTP id 738C443C9D for ; Fri, 1 Dec 2006 08:16:11 +0000 (GMT) (envelope-from nike_d@tormentor.totalterror.net) Received: (qmail 19856 invoked by uid 1009); 1 Dec 2006 10:16:22 +0200 Received: from nike_d@tormentor.totalterror.net by galileo by uid 1002 with qmail-scanner-1.22 (spamassassin: 3.0.3. Clear:RC:1(82.199.197.152):. Processed in 0.029227 secs); 01 Dec 2006 08:16:22 -0000 Received: from unknown (HELO tormentor.totalterror.net) (82.199.197.152) by galileo.sellinet.net with SMTP; 1 Dec 2006 10:16:22 +0200 Received: (qmail 30298 invoked by uid 1001); 1 Dec 2006 08:16:22 -0000 Message-Id: <20061201081622.30297.qmail@tormentor.totalterror.net> Date: 1 Dec 2006 08:16:22 -0000 From: Niki Denev To: FreeBSD-gnats-submit@FreeBSD.org X-Send-Pr-Version: 3.113 Cc: Subject: misc/106112: libalias treats every line in /etc/libalias.conf as loadable module (even the comments) X-BeenThere: freebsd-bugs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Niki Denev List-Id: Bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 01 Dec 2006 08:20:39 -0000 >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 , >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: