diff options
author | Yuri Pankov <[email protected]> | 2021-04-14 19:02:16 +0300 |
---|---|---|
committer | GitHub <[email protected]> | 2021-04-14 09:02:16 -0700 |
commit | 96904d879cc0a8ec3485806150a7e0311aa907bd (patch) | |
tree | 74314a7cb45d1605b92f4d7e81c684d224d43cb1 | |
parent | 3e660534eab18d05de0dfca49e4a5e8c27e2c9af (diff) |
Fix vdev health padding in zpool list -v
Do not (incorrectly, right instead left) pad health string itself,
it will be taken care of when printing property value below.
Reviewed-by: Brian Behlendorf <[email protected]>
Reviewed-by: Ryan Moeller <[email protected]>
Signed-off-by: Yuri Pankov <[email protected]>
Closes #11899
-rw-r--r-- | cmd/zpool/zpool_main.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/cmd/zpool/zpool_main.c b/cmd/zpool/zpool_main.c index 34742eab5..8d809acb2 100644 --- a/cmd/zpool/zpool_main.c +++ b/cmd/zpool/zpool_main.c @@ -6021,7 +6021,7 @@ print_one_column(zpool_prop_t prop, uint64_t value, const char *str, break; case ZPOOL_PROP_HEALTH: width = 8; - snprintf(propval, sizeof (propval), "%-*s", (int)width, str); + (void) strlcpy(propval, str, sizeof (propval)); break; default: zfs_nicenum_format(value, propval, sizeof (propval), format); |