JSON: fix user properties output for zfs list
commit57fc5971f6be634dc63642f15b37cc2349ed4bab
authorUmer Saleem <usaleem@ixsystems.com>
Thu, 7 Nov 2024 19:31:14 +0000 (8 00:31 +0500)
committerGitHub <noreply@github.com>
Thu, 7 Nov 2024 19:31:14 +0000 (7 11:31 -0800)
treeea05e5a299c6c957ba0ca9269a6ec28114133981
parent4a7a0a0290118382a2c7be320c6e14d72b0637a1
JSON: fix user properties output for zfs list

This commit fixes JSON output for zfs list when user properties are
requested with -o flag. This case needed to be handled specifically
since zfs_prop_to_name does not return property name for user
properties, instead it is stored in pl->pl_user_prop.

Reviewed-by: Ameer Hamza <ahamza@ixsystems.com>
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Reviewed-by: Alexander Motin <mav@FreeBSD.org>
Signed-off-by: Umer Saleem <usaleem@ixsystems.com>
Closes #16732
cmd/zfs/zfs_main.c