mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2025-01-22 04:25:18 +00:00
tests: Call virFileWrapperClearPrefixes() for tests using virFileWrapper
This is mostly to avoid a memleak that is not a true memleak anyway - prefixes will be freed by kernel upon test exit. Signed-off-by: Michal Privoznik <mprivozn@redhat.com> Reviewed-by: Martin Kletzander <mkletzan@redhat.com> Reviewed-by: Erik Skultety <eskultet@redhat.com>
This commit is contained in:
parent
6e31c4b27e
commit
ff86e79faf
@ -128,6 +128,8 @@ mymain(void)
|
||||
if (virTestRun("QEMU FW precedence test", testFWPrecedence, NULL) < 0)
|
||||
ret = -1;
|
||||
|
||||
virFileWrapperClearPrefixes();
|
||||
|
||||
return ret == 0 ? EXIT_SUCCESS : EXIT_FAILURE;
|
||||
}
|
||||
|
||||
|
@ -3044,6 +3044,7 @@ mymain(void)
|
||||
qemuTestDriverFree(&driver);
|
||||
VIR_FREE(fakerootdir);
|
||||
virHashFree(capslatest);
|
||||
virFileWrapperClearPrefixes();
|
||||
|
||||
return ret == 0 ? EXIT_SUCCESS : EXIT_FAILURE;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user