Skip to content

Commit 1cebe8a

Browse files
authored
libzfs: report invalid permission name in zfs allow
zfs allow with a typo (e.g. "snapshop") produced the misleading error "operation not applicable to datasets of this type". Report "invalid permission" instead. Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Reviewed-by: Tony Hutter <hutter2@llnl.gov> Signed-off-by: Christos Longros <chris.longros@gmail.com> Closes #18401 Closes #11903
1 parent 4339b4e commit 1cebe8a

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

lib/libzfs/libzfs_dataset.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5138,7 +5138,7 @@ zfs_set_fsacl(zfs_handle_t *zhp, boolean_t un, nvlist_t *nvl)
51385138
err = zfs_error(hdl, EZFS_BADVERSION, errbuf);
51395139
break;
51405140
case EINVAL:
5141-
err = zfs_error(hdl, EZFS_BADTYPE, errbuf);
5141+
err = zfs_error(hdl, EZFS_BADPERM, errbuf);
51425142
break;
51435143
case ENOENT:
51445144
err = zfs_error(hdl, EZFS_NOENT, errbuf);

0 commit comments

Comments
 (0)