Add const to nvlist functions to properly expose their real behavior

Reviewed-by: Matthew Ahrens <mahrens@delphix.com>
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Reviewed-by: Tony Nguyen <tony.nguyen@delphix.com>
Reviewed-by: Ryan Moeller <ryan@iXsystems.com>
Signed-off-by: Paul Dagnelie <pcd@delphix.com>
Closes #12728
This commit is contained in:
Paul Dagnelie
2021-12-06 17:19:13 -08:00
committed by GitHub
parent 14ba514af6
commit 795075e638
28 changed files with 728 additions and 621 deletions
+2 -2
View File
@@ -152,8 +152,8 @@ spa_generate_rootconf(const char *name)
fnvlist_add_string(nvroot, ZPOOL_CONFIG_TYPE, VDEV_TYPE_ROOT);
fnvlist_add_uint64(nvroot, ZPOOL_CONFIG_ID, 0ULL);
fnvlist_add_uint64(nvroot, ZPOOL_CONFIG_GUID, pgid);
fnvlist_add_nvlist_array(nvroot, ZPOOL_CONFIG_CHILDREN, tops,
nchildren);
fnvlist_add_nvlist_array(nvroot, ZPOOL_CONFIG_CHILDREN,
(const nvlist_t * const *)tops, nchildren);
/*
* Replace the existing vdev_tree with the new root vdev in