From: Peter Rajnoha <prajnoha@fedoraproject.org>
To: lvm-devel@redhat.com
Subject: master - cleanup: gcc warning
Date: Fri, 15 Aug 2014 13:33:29 +0000 (UTC) [thread overview]
Message-ID: <20140815133329.B85B0612EC@fedorahosted.org> (raw)
Gitweb: http://git.fedorahosted.org/git/?p=lvm2.git;a=commitdiff;h=8e449ebd63228bb8728d7e62989dc1254138b153
Commit: 8e449ebd63228bb8728d7e62989dc1254138b153
Parent: d213758e5720f47d3a5781d958431c8d80afdda7
Author: Peter Rajnoha <prajnoha@redhat.com>
AuthorDate: Fri Aug 15 15:32:04 2014 +0200
Committer: Peter Rajnoha <prajnoha@redhat.com>
CommitterDate: Fri Aug 15 15:32:04 2014 +0200
cleanup: gcc warning
metadata/lv_manip.c:269: warning: declaration of "snapshot_count" shadows a global declaration
There's existing function called "snapshot_count" so rename the
variable to "snap_count".
---
lib/metadata/lv_manip.c | 6 +++---
1 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/lib/metadata/lv_manip.c b/lib/metadata/lv_manip.c
index 35b898f..d86bdc1 100644
--- a/lib/metadata/lv_manip.c
+++ b/lib/metadata/lv_manip.c
@@ -266,7 +266,7 @@ static int _lv_type_list_thin(struct dm_pool *mem,
struct dm_list *type)
{
int top_level = 1;
- unsigned snapshot_count;
+ unsigned snap_count;
if (lv_is_thin_pool(lv)) {
if (!str_list_add_no_dup_check(mem, type, _lv_type_names[LV_TYPE_THIN]) ||
@@ -286,10 +286,10 @@ static int _lv_type_list_thin(struct dm_pool *mem,
} else if (lv_is_thin_volume(lv)) {
if (!str_list_add_no_dup_check(mem, type, _lv_type_names[LV_TYPE_THIN]))
goto_bad;
- if (lv_is_thin_origin(lv, &snapshot_count) &&
+ if (lv_is_thin_origin(lv, &snap_count) &&
!str_list_add_no_dup_check(mem, type, _lv_type_names[LV_TYPE_ORIGIN]))
goto_bad;
- if (snapshot_count > 1 &&
+ if (snap_count > 1 &&
!str_list_add_no_dup_check(mem, type, _lv_type_names[LV_TYPE_MULTIPLE]))
goto_bad;
if (first_seg(lv)->origin)
next reply other threads:[~2014-08-15 13:33 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-08-15 13:33 Peter Rajnoha [this message]
-- strict thread matches above, loose matches on Subject: below --
2014-08-15 13:44 master - cleanup: gcc warning Peter Rajnoha
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20140815133329.B85B0612EC@fedorahosted.org \
--to=prajnoha@fedoraproject.org \
--cc=lvm-devel@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.