aboutsummaryrefslogtreecommitdiffstats
path: root/cmd/zfs
diff options
context:
space:
mode:
authorнаб <[email protected]>2022-04-15 00:00:02 +0200
committerBrian Behlendorf <[email protected]>2022-05-18 12:52:10 -0700
commit2b4f2fc93c4298415c5bc70554514c3e8892e5d5 (patch)
tree6dacd72befb51adf0f0fc500b42ad0fe9edebf83 /cmd/zfs
parent38f4d99f769efbb472ab3c35558700163e4f023c (diff)
libzfs: return (allocated) strings instead of filling buffers
This also expands the zfs version output from 127 characters to However Many Are Actually Set Reviewed-by: Brian Behlendorf <[email protected]> Signed-off-by: Ahelenia Ziemiańska <[email protected]> Closes #13330
Diffstat (limited to 'cmd/zfs')
-rw-r--r--cmd/zfs/zfs_main.c6
1 files changed, 1 insertions, 5 deletions
diff --git a/cmd/zfs/zfs_main.c b/cmd/zfs/zfs_main.c
index 69f5bdf4d..6282d8946 100644
--- a/cmd/zfs/zfs_main.c
+++ b/cmd/zfs/zfs_main.c
@@ -8577,11 +8577,7 @@ static int
zfs_do_version(int argc, char **argv)
{
(void) argc, (void) argv;
-
- if (zfs_version_print() == -1)
- return (1);
-
- return (0);
+ return (zfs_version_print() != 0);
}
int