1
0
mirror of git://sourceware.org/git/lvm2.git synced 2024-12-23 21:35:29 +03:00

Fix memory leak in _process_one_vg error path.

Author: Dave Wysochanski <dwysocha@redhat.com>
This commit is contained in:
Dave Wysochanski 2009-07-15 12:15:36 +00:00
parent 4782f379e2
commit db5e7962c9

View File

@ -432,8 +432,10 @@ static int _process_one_vg(struct cmd_context *cmd, const char *vg_name,
vg = vg_read(cmd, vg_name, vgid, flags);
if (vg_read_error(vg) == FAILED_ALLOCATION ||
vg_read_error(vg) == FAILED_NOTFOUND)
vg_read_error(vg) == FAILED_NOTFOUND) {
vg_release(vg);
return ECMD_FAILED;
}
if (!dm_list_empty(tags)) {
/* Only process if a tag matches or it's on arg_vgnames */