mirror of
git://sourceware.org/git/lvm2.git
synced 2024-12-21 13:34:40 +03:00
fix memory leak
This commit is contained in:
parent
2eca35b6d6
commit
0153e94a50
@ -81,6 +81,8 @@ int lvactivate(int argc, char **argv)
|
||||
get_pe_offset(p, pv));
|
||||
}
|
||||
|
||||
if (pv)
|
||||
dbg_free(pv->pe);
|
||||
dbg_free(pv);
|
||||
dbg_free(lvs);
|
||||
}
|
||||
@ -88,6 +90,8 @@ int lvactivate(int argc, char **argv)
|
||||
return 0;
|
||||
|
||||
pvdisplay_device_out:
|
||||
if (pv)
|
||||
dbg_free(pv->pe);
|
||||
dbg_free(pv);
|
||||
dbg_free(lvs);
|
||||
|
||||
|
@ -131,6 +131,8 @@ void pvdisplay_device(const char *pv_name)
|
||||
log_print ("no logical volume on physical volume %s", pv_name);
|
||||
|
||||
pvdisplay_device_out:
|
||||
if (pv)
|
||||
dbg_free(pv->pe);
|
||||
dbg_free(pv);
|
||||
dbg_free(lvs);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user