From fd53d86eeada2b03fff2ca0ebb8ad25280b90cdd Mon Sep 17 00:00:00 2001 From: Zdenek Kabelac Date: Mon, 11 Jul 2016 22:58:21 +0200 Subject: [PATCH] cleanup: gcc warns removal Ensure vars have always defined value. --- lib/cache/lvmetad.c | 2 +- lib/metadata/raid_manip.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/cache/lvmetad.c b/lib/cache/lvmetad.c index 1fecb5edb..c320b1c82 100644 --- a/lib/cache/lvmetad.c +++ b/lib/cache/lvmetad.c @@ -1784,7 +1784,7 @@ static struct volume_group *lvmetad_pvscan_vg(struct cmd_context *cmd, struct vo struct dm_list pvs_scan; struct dm_list pvs_drop; struct dm_list pvs_new; - struct lvmcache_info *info; + struct lvmcache_info *info = NULL; struct format_instance *fid; struct format_instance_ctx fic = { .type = 0 }; struct _lvmetad_pvscan_baton baton; diff --git a/lib/metadata/raid_manip.c b/lib/metadata/raid_manip.c index b67380fcb..9ac061f34 100644 --- a/lib/metadata/raid_manip.c +++ b/lib/metadata/raid_manip.c @@ -1726,7 +1726,7 @@ static int _raid0_to_striped_retrieve_segments_and_lvs(struct logical_volume *lv struct dm_list *removal_lvs) { uint32_t s, area_le, area_len, le; - struct lv_segment *data_seg, *seg, *seg_to; + struct lv_segment *data_seg = NULL, *seg, *seg_to; struct dm_list new_segments; seg = first_seg(lv);