diff options
author | Brian Behlendorf <[email protected]> | 2010-08-26 09:52:41 -0700 |
---|---|---|
committer | Brian Behlendorf <[email protected]> | 2010-08-27 15:34:03 -0700 |
commit | 2598c0012dc33496539ce893a0af601c66cbb7e2 (patch) | |
tree | c0523910cfa96a281a85063b113fc5f2bb05e7a2 /module/zfs | |
parent | 0bc8fd7884fc603eb7646c43b1fc0b18e37e7d62 (diff) |
Fix gcc missing braces warnings
Resolve compiler warnings concerning missing braces.
Signed-off-by: Brian Behlendorf <[email protected]>
Diffstat (limited to 'module/zfs')
-rw-r--r-- | module/zfs/arc.c | 3 | ||||
-rw-r--r-- | module/zfs/dsl_dataset.c | 3 | ||||
-rw-r--r-- | module/zfs/dsl_scan.c | 4 |
3 files changed, 7 insertions, 3 deletions
diff --git a/module/zfs/arc.c b/module/zfs/arc.c index 6b57f51ff..d6d648c65 100644 --- a/module/zfs/arc.c +++ b/module/zfs/arc.c @@ -1745,13 +1745,14 @@ static void arc_evict_ghost(arc_state_t *state, uint64_t spa, int64_t bytes) { arc_buf_hdr_t *ab, *ab_prev; - arc_buf_hdr_t marker = { 0 }; + arc_buf_hdr_t marker; list_t *list = &state->arcs_list[ARC_BUFC_DATA]; kmutex_t *hash_lock; uint64_t bytes_deleted = 0; uint64_t bufs_skipped = 0; ASSERT(GHOST_STATE(state)); + bzero(&marker, sizeof(marker)); top: mutex_enter(&state->arcs_mtx); for (ab = list_tail(list); ab; ab = ab_prev) { diff --git a/module/zfs/dsl_dataset.c b/module/zfs/dsl_dataset.c index 667aef37e..8c6f3fbea 100644 --- a/module/zfs/dsl_dataset.c +++ b/module/zfs/dsl_dataset.c @@ -2923,10 +2923,11 @@ dsl_dataset_promote(const char *name, char *conflsnap) dsl_dir_t *dd; dsl_pool_t *dp; dmu_object_info_t doi; - struct promotearg pa = { 0 }; + struct promotearg pa; struct promotenode *snap; int err; + bzero(&pa, sizeof(struct promotearg)); err = dsl_dataset_hold(name, FTAG, &ds); if (err) return (err); diff --git a/module/zfs/dsl_scan.c b/module/zfs/dsl_scan.c index 7e6be15a0..e18dadf44 100644 --- a/module/zfs/dsl_scan.c +++ b/module/zfs/dsl_scan.c @@ -1251,10 +1251,12 @@ static void dsl_scan_ddt(dsl_scan_t *scn, dmu_tx_t *tx) { ddt_bookmark_t *ddb = &scn->scn_phys.scn_ddt_bookmark; - ddt_entry_t dde = { 0 }; + ddt_entry_t dde; int error; uint64_t n = 0; + bzero(&dde, sizeof (ddt_entry_t)); + while ((error = ddt_walk(scn->scn_dp->dp_spa, ddb, &dde)) == 0) { ddt_t *ddt; |