From owner-freebsd-ipfw Tue Dec 12 18: 8:31 2000 From owner-freebsd-ipfw@FreeBSD.ORG Tue Dec 12 18:08:29 2000 Return-Path: Delivered-To: freebsd-ipfw@freebsd.org Received: from chmls20.mediaone.net (chmls20.mediaone.net [24.147.1.156]) by hub.freebsd.org (Postfix) with ESMTP id 69EFC37B402 for ; Tue, 12 Dec 2000 18:08:29 -0800 (PST) Received: from acm.org (reyim.ne.mediaone.net [24.218.251.241]) by chmls20.mediaone.net (8.8.7/8.8.7) with ESMTP id VAA28846; Tue, 12 Dec 2000 21:08:16 -0500 (EST) Message-ID: <3A36DA0C.1B005960@acm.org> Date: Tue, 12 Dec 2000 21:08:12 -0500 From: Jim Bloom X-Mailer: Mozilla 4.75 [en]C-MOENE (Win98; U) X-Accept-Language: en MIME-Version: 1.0 To: Chris Browning Cc: freebsd-ipfw@FreeBSD.ORG Subject: Re: suck in config vars in rc.firewall References: <200012130147.UAA09876@mail3.lig.bellsouth.net> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-ipfw@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG Chris Browning wrote: > > This has been bugging me. Could someone explain why > rc.firewall seems to take config variables from > etc/defaults/rc.conf instead of /etc/rc.conf?... > > # Suck in the configuration variables. > if [ -f /etc/defaults/rc.conf ]; then > . /etc/defaults/rc.conf > elif [ -f /etc/rc.conf ]; then > . /etc/rc.conf > fi > > Is my understanding of if/elif/fi and test faulty? Thanks. Nope, your understanding is correct. What you missed is that /etc/defaults/rc.conf reads in /etc/rc.conf at the end. It takes a bit of variable following to see how this occurs. Jim Bloom bloom@acm.org To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-ipfw" in the body of the message