1
0
mirror of git://sourceware.org/git/lvm2.git synced 2025-01-18 10:04:20 +03:00

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".
This commit is contained in:
Peter Rajnoha 2014-08-15 15:32:04 +02:00
parent d213758e57
commit 8e449ebd63

View File

@ -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)