mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2025-03-07 17:28:15 +00:00
tests: nodeinfotest: Remove virSaveLastError() usage
It's overkill here, we can use virGetLast* instead
This commit is contained in:
parent
b29e08dbe3
commit
ee814d0ec4
@ -44,10 +44,8 @@ linuxTestCompareFiles(char *sysfs_prefix,
|
||||
memset(&nodeinfo, 0, sizeof(nodeinfo));
|
||||
if (linuxNodeInfoCPUPopulate(sysfs_prefix, cpuinfo, arch, &nodeinfo) < 0) {
|
||||
if (virTestGetDebug()) {
|
||||
virErrorPtr error = virSaveLastError();
|
||||
if (error && error->code != VIR_ERR_OK)
|
||||
VIR_TEST_DEBUG("\n%s\n", error->message);
|
||||
virFreeError(error);
|
||||
if (virGetLastError())
|
||||
VIR_TEST_DEBUG("\n%s\n", virGetLastErrorMessage());
|
||||
}
|
||||
VIR_FORCE_FCLOSE(cpuinfo);
|
||||
goto fail;
|
||||
|
Loading…
x
Reference in New Issue
Block a user