Author: mav
Date: Wed Sep 14 09:12:49 2016
New Revision: 305799
URL: https://svnweb.freebsd.org/changeset/base/305799
Log:
MFC r305123: Fix kernel panic when inheriting properties without default.
There are two writable hidden properties "iscsioptions" and "stmf_sbd_lu",
that have no default string value. Attempt to unset them or replicate
caused kernel panic. This simple bandaid seems fixes the problem nicely.
Modified:
stable/11/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dsl_prop.c
Directory Properties:
stable/11/ (props changed)
Modified: stable/11/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dsl_prop.c
==============================================================================
--- stable/11/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dsl_prop.c Wed Sep
14 09:11:03 2016 (r305798)
+++ stable/11/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dsl_prop.c Wed Sep
14 09:12:49 2016 (r305799)
@@ -54,6 +54,8 @@ dodefault(zfs_prop_t prop, int intsz, in
return (SET_ERROR(ENOENT));
if (zfs_prop_get_type(prop) == PROP_TYPE_STRING) {
+ if (zfs_prop_default_string(prop) == NULL)
+ return (SET_ERROR(ENOENT));
if (intsz != 1)
return (SET_ERROR(EOVERFLOW));
(void) strncpy(buf, zfs_prop_default_string(prop),
_______________________________________________
[email protected] mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "[email protected]"