diff options
author | Brian Behlendorf <[email protected]> | 2019-11-13 09:23:14 -0800 |
---|---|---|
committer | GitHub <[email protected]> | 2019-11-13 09:23:14 -0800 |
commit | 94a570e39c35522ad3bedf6f7873ca18e6422e91 (patch) | |
tree | 64af442db4d5b57bb45caa954ec5ec71a7efbe76 | |
parent | c5ebfbbe1978d4488f68489aadf003774e7e4672 (diff) |
Fix `zpool create -o <property>` error message
When `zpool create -o <property>` is run without root permissions
and the pool property requested is not specifically enumerated in
zpool_valid_proplist(). Then an incorrect error message referring
to an invalid property is printed rather than the expected permission
denied error.
Specifying a pool property at create time should be handled the same
way as filesystem properties in zfs_valid_proplist(). There should
not be default zfs_error_aux() set for properties which are not
listed.
Reviewed-by: loli10K <[email protected]>
Reviewed-by: Kjeld Schouten <[email protected]>
Signed-off-by: Brian Behlendorf <[email protected]>
Closes #9550
Closes #9568
-rw-r--r-- | lib/libzfs/libzfs_pool.c | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/lib/libzfs/libzfs_pool.c b/lib/libzfs/libzfs_pool.c index 1a97c1666..7f3ec5d0d 100644 --- a/lib/libzfs/libzfs_pool.c +++ b/lib/libzfs/libzfs_pool.c @@ -724,8 +724,6 @@ zpool_valid_proplist(libzfs_handle_t *hdl, const char *poolname, break; default: - zfs_error_aux(hdl, dgettext(TEXT_DOMAIN, - "property '%s'(%d) not defined"), propname, prop); break; } } |