diff options
author | Zdenek Kabelac <zkabelac@redhat.com> | 2011-02-18 16:17:56 +0000 |
---|---|---|
committer | Zdenek Kabelac <zkabelac@redhat.com> | 2011-02-18 16:17:56 +0000 |
commit | faf2288895deba6b5b91da71f62a45a0ef7d75fa (patch) | |
tree | acd38622bbe982df9059d9ca60e70c3861a04871 /tools | |
parent | eb4188830e8c6b44fcbb7a7da02c6b6438da3605 (diff) | |
download | lvm2-faf2288895deba6b5b91da71f62a45a0ef7d75fa.tar.gz lvm2-faf2288895deba6b5b91da71f62a45a0ef7d75fa.tar.xz lvm2-faf2288895deba6b5b91da71f62a45a0ef7d75fa.zip |
Fix gcc warnings for unused variables
Put dead assigment code into comment.
Diffstat (limited to 'tools')
-rw-r--r-- | tools/dmsetup.c | 5 | ||||
-rw-r--r-- | tools/vgconvert.c | 5 |
2 files changed, 4 insertions, 6 deletions
diff --git a/tools/dmsetup.c b/tools/dmsetup.c index 86937f00..216f4efe 100644 --- a/tools/dmsetup.c +++ b/tools/dmsetup.c @@ -2998,7 +2998,6 @@ error: static int _process_losetup_switches(const char *base, int *argc, char ***argv, const char *dev_dir) { - static int ind; int c; int encrypt_loop = 0, delete = 0, find = 0, show_all = 0; char *device_name = NULL; @@ -3013,8 +3012,8 @@ static int _process_losetup_switches(const char *base, int *argc, char ***argv, optarg = 0; optind = OPTIND_INIT; - while ((ind = -1, c = GETOPTLONG_FN(*argc, *argv, "ade:fo:v", - long_options, NULL)) != -1 ) { + while ((c = GETOPTLONG_FN(*argc, *argv, "ade:fo:v", + long_options, NULL)) != -1 ) { if (c == ':' || c == '?') return 0; if (c == 'a') diff --git a/tools/vgconvert.c b/tools/vgconvert.c index acae0fcf..729ce389 100644 --- a/tools/vgconvert.c +++ b/tools/vgconvert.c @@ -26,7 +26,7 @@ static int vgconvert_single(struct cmd_context *cmd, const char *vg_name, struct dm_list mdas; int pvmetadatacopies = 0; uint64_t pvmetadatasize = 0; - uint64_t pe_end = 0, pe_start = 0; + uint64_t pe_start = 0; struct pv_list *pvl; int change_made = 0; struct lvinfo info; @@ -119,8 +119,7 @@ static int vgconvert_single(struct cmd_context *cmd, const char *vg_name, existing_pv = pvl->pv; pe_start = pv_pe_start(existing_pv); - pe_end = pv_pe_count(existing_pv) * pv_pe_size(existing_pv) - + pe_start - 1; + /* pe_end = pv_pe_count(existing_pv) * pv_pe_size(existing_pv) + pe_start - 1; */ dm_list_init(&mdas); if (!(pv = pv_create(cmd, pv_dev(existing_pv), |