From owner-freebsd-arch@FreeBSD.ORG Wed Jun 1 15:32:25 2005 Return-Path: X-Original-To: freebsd-arch@FreeBSD.org Delivered-To: freebsd-arch@FreeBSD.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id DCB5316A41C for ; Wed, 1 Jun 2005 15:32:25 +0000 (GMT) (envelope-from trhodes@FreeBSD.org) Received: from pittgoth.com (14.zlnp1.xdsl.nauticom.net [209.195.149.111]) by mx1.FreeBSD.org (Postfix) with ESMTP id 81ADE43D53 for ; Wed, 1 Jun 2005 15:32:23 +0000 (GMT) (envelope-from trhodes@FreeBSD.org) Received: from mobile.pittgoth.com (ip68-105-180-6.dc.dc.cox.net [68.105.180.6]) (authenticated bits=0) by pittgoth.com (8.13.3/8.13.3) with ESMTP id j51FWC2L066388 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NOT); Wed, 1 Jun 2005 11:32:13 -0400 (EDT) (envelope-from trhodes@FreeBSD.org) Date: Wed, 1 Jun 2005 11:31:26 -0400 From: Tom Rhodes To: Bruce Evans Message-ID: <20050601113126.2949ff1e@mobile.pittgoth.com> In-Reply-To: <20050601211628.V96009@delplex.bde.org> References: <1117613456.771.16.camel@spirit> <20050601211628.V96009@delplex.bde.org> X-Mailer: Sylpheed-Claws 1.0.1 (GTK+ 1.2.10; i386-portbld-freebsd6.0) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Cc: delphij@delphij.net, freebsd-arch@FreeBSD.org Subject: Re: [PATCH RFC] Add a macro for null mount options to sbin/mount* X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 01 Jun 2005 15:32:26 -0000 On Wed, 1 Jun 2005 21:23:23 +1000 (EST) Bruce Evans wrote: > On Wed, 1 Jun 2005, Xin LI wrote: Here we go again! :P > > > In our mount* utilities, the null mount option, which is usually be used > > as a terminator of an option vector, is defined with some hand-rolled > > terms, e.g.: {NULL}, {NULL, 0, 0, 0}, etc. > > "{ NULL }" is the documented way. See getmntopts.3. That manual page has been unhooked since it's import IIRC. > > > I think it would be nice to have a new macro to deal with this, say, > > MOPT_NULL, which would be extended to {NULL, 0, 0, 0}, which can act as > > an explicit initialize. And in my opinion, something like: > > > > %%% > > opt = { > > MOPT_STD, > > MOPT_NULL > > }; > > %%% > > MOPT_NULL is a poor name. It is not a null option, but a terminator that > happens to have nulls in it. But MOPT_END is a better name, I like it. :) -- Tom Rhodes