mirror of
git://sourceware.org/git/lvm2.git
synced 2025-01-03 05:18:29 +03:00
pvck: avoid memleak of vgname
clang: no vgname buffer leak.
This commit is contained in:
parent
ac38b576f9
commit
1bde35e596
@ -788,7 +788,7 @@ static int _dump_current_text(struct device *dev,
|
||||
{
|
||||
char *meta_buf;
|
||||
struct dm_config_tree *cft;
|
||||
const char *vgname = NULL;
|
||||
char *vgname = NULL;
|
||||
uint32_t crc;
|
||||
uint32_t seqno = 0;
|
||||
int mn = mda_num; /* 1 or 2 */
|
||||
@ -895,6 +895,7 @@ static int _dump_current_text(struct device *dev,
|
||||
|
||||
out:
|
||||
free(meta_buf);
|
||||
free(vgname);
|
||||
if (bad)
|
||||
return 0;
|
||||
return 1;
|
||||
|
Loading…
Reference in New Issue
Block a user