mirror of
git://sourceware.org/git/lvm2.git
synced 2024-12-21 13:34:40 +03:00
coverity: eliminate DEADCODE
Coverity notice this cannot be NULL: cur = &dms->regions[*cur_r] so avoid NULL checking and simplify form.
This commit is contained in:
parent
8173c2ff9a
commit
36d0dcef38
@ -957,15 +957,13 @@ bad:
|
||||
static void _stats_walk_next(const struct dm_stats *dms, int region,
|
||||
uint64_t *cur_r, uint64_t *cur_a)
|
||||
{
|
||||
struct dm_stats_region *cur = NULL;
|
||||
struct dm_stats_region *cur;
|
||||
int present;
|
||||
|
||||
if (!dms || !dms->regions)
|
||||
return;
|
||||
|
||||
if (!(cur = &dms->regions[*cur_r]))
|
||||
return;
|
||||
|
||||
cur = dms->regions + *cur_r;
|
||||
present = _stats_region_present(cur);
|
||||
|
||||
if (region && present)
|
||||
|
Loading…
Reference in New Issue
Block a user