]> git.ipfire.org Git - thirdparty/xfsprogs-dev.git/commit - mkfs/xfs_mkfs.c
mkfs: pass switch case value directly into getnum/getstr
authorEric Sandeen <sandeen@redhat.com>
Thu, 4 Jan 2018 19:56:50 +0000 (13:56 -0600)
committerEric Sandeen <sandeen@redhat.com>
Thu, 4 Jan 2018 19:56:50 +0000 (13:56 -0600)
commite5e612ae728a9c88aa8eeefdaf61f4a65513b49d
treee800327e3f49a883a8cf9b28dbc693a8e08f48c2
parentc66bd30ed7aecb429cfe3400c32892d7bc78e75b
mkfs: pass switch case value directly into getnum/getstr

Parsing did this sort of thing:

case D_AGCOUNT:
cli->agcount = getnum(value, opts, D_AGCOUNT);

which was just begging for a cut and paste error between the
case value and the enum passed into getnum/getstr.  Pass
"subopt" instead so that it is always consistent with the case.

Signed-off-by: Eric Sandeen <sandeen@sandeen.net>
Reviewed-by: Darrick J. Wong <darrick.wong@oracle.com>
Signed-off-by: Eric Sandeen <sandeen@sandeen.net>
mkfs/xfs_mkfs.c