From owner-freebsd-rc@FreeBSD.ORG Tue Dec 21 16:50:06 2010 Return-Path: Delivered-To: freebsd-rc@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id B09FD106566C for ; Tue, 21 Dec 2010 16:50:06 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:4f8:fff6::28]) by mx1.freebsd.org (Postfix) with ESMTP id 9A5A48FC12 for ; Tue, 21 Dec 2010 16:50:06 +0000 (UTC) Received: from freefall.freebsd.org (localhost [127.0.0.1]) by freefall.freebsd.org (8.14.4/8.14.4) with ESMTP id oBLGo67h075759 for ; Tue, 21 Dec 2010 16:50:06 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.4/8.14.4/Submit) id oBLGo6UC075758; Tue, 21 Dec 2010 16:50:06 GMT (envelope-from gnats) Date: Tue, 21 Dec 2010 16:50:06 GMT Message-Id: <201012211650.oBLGo6UC075758@freefall.freebsd.org> To: freebsd-rc@FreeBSD.org From: Jaakko Heinonen Cc: Subject: Re: conf/91342: [devfs] Errors in devfs.rules files don't get logged X-BeenThere: freebsd-rc@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Jaakko Heinonen List-Id: "Discussion related to /etc/rc.d design and implementation." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 21 Dec 2010 16:50:06 -0000 The following reply was made to PR conf/91342; it has been noted by GNATS. From: Jaakko Heinonen To: bug-followup@FreeBSD.org, guy@alum.mit.edu Cc: Subject: Re: conf/91342: [devfs] Errors in devfs.rules files don't get logged Date: Tue, 21 Dec 2010 18:45:15 +0200 Guy Harris wrote: > If there's an error in /etc/defaults/devfs.rules or /etc/devfs.rules, > no error message about the error appears in, for example, > /var/log/messages. How about this patch? %%% Index: etc/rc.subr =================================================================== --- etc/rc.subr (revision 216581) +++ etc/rc.subr (working copy) @@ -1349,7 +1349,10 @@ devfs_init_rulesets() return fi for file in $devfs_rulesets; do - devfs_rulesets_from_file $file || return 1 + if ! devfs_rulesets_from_file $file; then + warn "$_me: could not read rules from $file" + return 1 + fi done devfs_rulesets_init=1 debug "$_me: devfs rulesets initialized" %%% -- Jaakko