Fix gcc missing parenthesis warnings
[zfs.git] / lib / libzfs / libzfs_import.c
index e137035..9629ab0 100644 (file)
@@ -370,7 +370,7 @@ static nvlist_t *
 refresh_config(libzfs_handle_t *hdl, nvlist_t *config)
 {
        nvlist_t *nvl;
-       zfs_cmd_t zc = { 0 };
+       zfs_cmd_t zc = { "\0", "\0", "\0", "\0", 0 };
        int err;
 
        if (zcmd_write_conf_nvlist(hdl, &zc, config) != 0)
@@ -410,7 +410,9 @@ refresh_config(libzfs_handle_t *hdl, nvlist_t *config)
 boolean_t
 vdev_is_hole(uint64_t *hole_array, uint_t holes, uint_t id)
 {
-       for (int c = 0; c < holes; c++) {
+       int c;
+
+       for (c = 0; c < holes; c++) {
 
                /* Top-level is a hole */
                if (hole_array[c] == id)