1
0
mirror of git://sourceware.org/git/lvm2.git synced 2025-03-10 16:58:47 +03:00

Instrument code that pointer are already released

Set pointers to NULL since on the function exit they are no longer valid.
This commit is contained in:
Zdenek Kabelac 2012-01-25 22:35:36 +00:00
parent 254944d890
commit 96bffe6a4a

View File

@ -757,11 +757,15 @@ static int _text_vg_export(struct formatter *f,
r = 1;
out:
if (f->mem)
if (f->mem) {
dm_pool_destroy(f->mem);
f->mem = NULL;
}
if (f->pv_names)
if (f->pv_names) {
dm_hash_destroy(f->pv_names);
f->pv_names = NULL;
}
return r;
}