diff --git a/zfs/lib/libzfs/libzfs_changelist.c b/zfs/lib/libzfs/libzfs_changelist.c index b905bc6cb6..8823b2e694 100644 --- a/zfs/lib/libzfs/libzfs_changelist.c +++ b/zfs/lib/libzfs/libzfs_changelist.c @@ -140,6 +140,8 @@ changelist_prefix(prop_changelist_t *clp) */ (void) zfs_unshare_iscsi(cn->cn_handle); break; + default: + break; } } else { /* @@ -156,6 +158,8 @@ changelist_prefix(prop_changelist_t *clp) case ZFS_PROP_SHARESMB: (void) zfs_unshare_smb(cn->cn_handle, NULL); break; + default: + break; } } } diff --git a/zfs/lib/libzfs/libzfs_dataset.c b/zfs/lib/libzfs/libzfs_dataset.c index 4aeb9bd091..266914aed2 100644 --- a/zfs/lib/libzfs/libzfs_dataset.c +++ b/zfs/lib/libzfs/libzfs_dataset.c @@ -72,6 +72,8 @@ zfs_type_to_name(zfs_type_t type) return (dgettext(TEXT_DOMAIN, "snapshot")); case ZFS_TYPE_VOLUME: return (dgettext(TEXT_DOMAIN, "volume")); + default: + break; } return (NULL); @@ -181,6 +183,8 @@ zfs_validate_name(libzfs_handle_t *hdl, const char *path, int type, zfs_error_aux(hdl, dgettext(TEXT_DOMAIN, "reserved disk name")); break; + default: + break; } } @@ -722,6 +726,8 @@ zfs_valid_proplist(libzfs_handle_t *hdl, zfs_type_t type, nvlist_t *nvl, "component of '%s' is too long"), propname); break; + default: + break; } (void) zfs_error(hdl, EZFS_BADPROP, errbuf); goto error; @@ -846,6 +852,8 @@ zfs_valid_proplist(libzfs_handle_t *hdl, zfs_type_t type, nvlist_t *nvl, case ZFS_PROP_NORMALIZE: chosen_normal = (int)intval; break; + default: + break; } /* @@ -894,6 +902,8 @@ zfs_valid_proplist(libzfs_handle_t *hdl, zfs_type_t type, nvlist_t *nvl, goto error; } break; + default: + break; } } } @@ -1136,6 +1146,8 @@ zfs_build_perms(zfs_handle_t *zhp, char *whostr, char *perms, dgettext(TEXT_DOMAIN, "set definition must begin with an '@' " "character")); + default: + break; } return (zfs_error(zhp->zfs_hdl, EZFS_BADPERMSET, whostr)); @@ -1565,6 +1577,8 @@ zfs_perm_get(zfs_handle_t *zhp, zfs_allow_t **zfs_perms) &nvpair_name(who_pair)[3]); tree = &zallowp->z_sets; break; + default: + break; } /* @@ -1717,6 +1731,8 @@ zfs_deleg_perm_type_str(zfs_deleg_perm_type_t type) return (dgettext(TEXT_DOMAIN, "property")); case ZFS_DELEG_OTHER: return (dgettext(TEXT_DOMAIN, "other")); + default: + break; } return (""); } @@ -2114,6 +2130,8 @@ get_numeric_property(zfs_handle_t *zhp, zfs_prop_t prop, zprop_source_t *src, mntopt_on = MNTOPT_NBMAND; mntopt_off = MNTOPT_NONBMAND; break; + default: + break; } /* diff --git a/zfs/lib/libzpool/spa.c b/zfs/lib/libzpool/spa.c index fb1b96f8b8..7ac5f240ec 100644 --- a/zfs/lib/libzpool/spa.c +++ b/zfs/lib/libzpool/spa.c @@ -393,6 +393,8 @@ spa_prop_validate(spa_t *spa, nvlist_t *props) strcmp(slash, "/..") == 0) error = EINVAL; break; + default: + break; } if (error) diff --git a/zfs/lib/libzpool/vdev_label.c b/zfs/lib/libzpool/vdev_label.c index bf930466fb..640ab79579 100644 --- a/zfs/lib/libzpool/vdev_label.c +++ b/zfs/lib/libzpool/vdev_label.c @@ -458,6 +458,8 @@ vdev_inuse(vdev_t *vd, uint64_t crtxg, vdev_labeltype_t reason, case VDEV_LABEL_SPARE: return (spa_has_spare(spa, device_guid)); + default: + break; } } diff --git a/zfs/lib/libzpool/zfs_ioctl.c b/zfs/lib/libzpool/zfs_ioctl.c index 62e105b471..b77ee4da38 100644 --- a/zfs/lib/libzpool/zfs_ioctl.c +++ b/zfs/lib/libzpool/zfs_ioctl.c @@ -349,6 +349,8 @@ zfs_secpolicy_setprop(const char *name, zfs_prop_t prop, cred_t *cr) return (EPERM); } break; + default: + break; } return (zfs_secpolicy_write_perms(name, zfs_prop_to_name(prop), cr)); @@ -1472,6 +1474,8 @@ zfs_set_prop_nvlist(const char *name, nvlist_t *nvl) SPA_VERSION_PASSTHROUGH_X)) return (ENOTSUP); } + default: + break; } elem = NULL;