Author: mckusick
Date: Mon Jun 26 17:33:33 2017
New Revision: 320366
URL: https://svnweb.freebsd.org/changeset/base/320366
Log:
MFC of 320176:
Allow '_' in labels when specifying -L to newfs.
PR: 220163
Reported by: Keve Nagy
Reviewed by: kib
Modified:
stable/10/sbin/newfs/newfs.c
Directory Properties:
stable/10/ (props changed)
Modified: stable/10/sbin/newfs/newfs.c
==============================================================================
--- stable/10/sbin/newfs/newfs.c Mon Jun 26 17:29:32 2017
(r320365)
+++ stable/10/sbin/newfs/newfs.c Mon Jun 26 17:33:33 2017
(r320366)
@@ -153,7 +153,8 @@ main(int argc, char *argv[])
case 'L':
volumelabel = optarg;
i = -1;
- while (isalnum(volumelabel[++i]));
+ while (isalnum(volumelabel[++i]) ||
+ volumelabel[i] == '_');
if (volumelabel[i] != '\0') {
errx(1, "bad volume label. Valid characters are
alphanumerics.");
}
_______________________________________________
[email protected] mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-stable-10
To unsubscribe, send any mail to "[email protected]"