Re: [PATCH RFC] Add a macro for null mount options to sbin/mount*

[ Available lists | Index of freebsd-arch | Month of Jun 2005 | Week of 1 Jun 2005 | Raw email | View thread | Wrap long lines | Reply ]
From
Maxime Henrion <mux@FreeBSD.org>
Date
1 Jun 2005 09:17:35
Subject
Re: [PATCH RFC] Add a macro for null mount options to sbin/mount*
Message-ID
20050601091734.GA14661@elvis.mu.org

In reply to
References to

[ Hide this part ]
Xin LI wrote:
> Hi, -arch@,
>
> 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.
>
> 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
> };
> %%%
>
> Looks better than:
>
> %%%
> opt = {
> MOPT_STD,
> { NULL }
> };
> %%%
>
> That has lead to the attached patchset. May I go ahead and commit it?

This is definitely nice. Please commit!

Cheers,
Maxime


Elapsed time: 0.121 seconds