svn commit: r343449 - in head/sbin: newfs tunefs
Rodney W. Grimes
freebsd at pdx.rh.CN85.dnsmgr.net
Fri Jan 25 20:15:48 UTC 2019
> Author: mckusick
> Date: Fri Jan 25 20:07:18 2019
> New Revision: 343449
> URL: https://svnweb.freebsd.org/changeset/base/343449
>
> Log:
> Allow tunefs to include '_' as a legal character in label names
> to make it consistent with newfs. Document the legality of '_'
> in label names in both tunefs(8) and newfs(8).
>
> PR: 235182
> Submitted by: darius at dons.net.au
> Reviewed by: Conrad Meyer
> MFC after: 3 days
> Sponsored by: Netflix
>
> Modified:
> head/sbin/newfs/newfs.8
> head/sbin/tunefs/tunefs.8
> head/sbin/tunefs/tunefs.c
>
> Modified: head/sbin/newfs/newfs.8
> ==============================================================================
> --- head/sbin/newfs/newfs.8 Fri Jan 25 20:02:55 2019 (r343448)
> +++ head/sbin/newfs/newfs.8 Fri Jan 25 20:07:18 2019 (r343449)
> @@ -89,6 +89,7 @@ See
> for details.
> .It Fl L Ar volname
> Add a volume label to the new file system.
> +Legal characters are alphanumerics and underscores.
> .It Fl N
> Cause the file system parameters to be printed out
> without really creating the file system.
>
> Modified: head/sbin/tunefs/tunefs.8
> ==============================================================================
> --- head/sbin/tunefs/tunefs.8 Fri Jan 25 20:02:55 2019 (r343448)
> +++ head/sbin/tunefs/tunefs.8 Fri Jan 25 20:07:18 2019 (r343449)
> @@ -112,6 +112,7 @@ By default
> sets it to half of the space reserved to minfree.
> .It Fl L Ar volname
> Add/modify an optional file system volume label.
> +Legal characters are alphanumerics and underscores.
> .It Fl l Cm enable | disable
> Turn on/off MAC multilabel flag.
> .It Fl m Ar minfree
>
> Modified: head/sbin/tunefs/tunefs.c
> ==============================================================================
> --- head/sbin/tunefs/tunefs.c Fri Jan 25 20:02:55 2019 (r343448)
> +++ head/sbin/tunefs/tunefs.c Fri Jan 25 20:07:18 2019 (r343449)
> @@ -189,7 +189,7 @@ main(int argc, char *argv[])
> name = "volume label";
> Lvalue = optarg;
> i = -1;
> - while (isalnum(Lvalue[++i]));
> + while (isalnum(Lvalue[++i]) || Lvalue[i] == '_');
> if (Lvalue[i] != '\0') {
> errx(10,
> "bad %s. Valid characters are alphanumerics.",
^^^^^^^^^^^^
This message is now incorrect.
--
Rod Grimes rgrimes at freebsd.org
More information about the svn-src-all
mailing list