Juli Mallett e9de7669c3 Improve unit parsing of mpsutil.
Previously, it used atoi(3) to parse the unit parameter, which would silently
yield a unit of 0 in the presence of an invalid unit number.  As most users of
mpsutil(8) are likely to have at least a unit 0, this is could have confusing
results.

This behaviour was particularly unintuitive if one incorrectly passed an
adapter device name, or a device path, instead of a unit number.  In addition
to using strtoumax(3) instead of atoi(3) to parse unit numbers, support
stripping a device name (e.g. mps1) or path (e.g. /dev/mps2) to just its unit
number.

Reviewed by:	scottl (earlier version)
2020-06-16 19:21:28 +00:00
..
2019-09-04 13:47:38 +00:00
2019-02-04 21:28:25 +00:00
2019-09-04 13:47:38 +00:00
2020-06-16 19:21:28 +00:00
2019-09-04 13:47:38 +00:00