qemu: command: Don't bother reporting errors in smbios formatters

qemuBuildSmbiosBiosStr and qemuBuildSmbiosSystemStr return NULL if
there's nothing to format on the commandline. Reporting errors from
buffer creation doesn't make sense since it would be ignored.
This commit is contained in:
Peter Krempa 2016-10-10 06:03:57 +02:00
parent 8d67e2849e
commit ec45439512
1 changed files with 0 additions and 14 deletions

View File

@ -5633,14 +5633,7 @@ qemuBuildSmbiosBiosStr(virSysinfoBIOSDefPtr def)
if (def->release)
virBufferAsprintf(&buf, ",release=%s", def->release);
if (virBufferCheckError(&buf) < 0)
goto error;
return virBufferContentAndReset(&buf);
error:
virBufferFreeAndReset(&buf);
return NULL;
}
@ -5681,14 +5674,7 @@ qemuBuildSmbiosSystemStr(virSysinfoSystemDefPtr def,
if (def->family)
virBufferAsprintf(&buf, ",family=%s", def->family);
if (virBufferCheckError(&buf) < 0)
goto error;
return virBufferContentAndReset(&buf);
error:
virBufferFreeAndReset(&buf);
return NULL;
}