mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2024-12-22 05:35:25 +00:00
qemu: Fix return value for qemuFirmwareFillDomainLegacy()
The documentation states that, just like the Modern() variant, this function should return 1 if a match wasn't found. It currently doesn't do that, and returns 0 instead. Signed-off-by: Andrea Bolognani <abologna@redhat.com> Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
This commit is contained in:
parent
4ba04107d9
commit
d917883b30
@ -1575,17 +1575,17 @@ qemuFirmwareFillDomainLegacy(virQEMUDriver *driver,
|
||||
size_t i;
|
||||
|
||||
if (!loader)
|
||||
return 0;
|
||||
return 1;
|
||||
|
||||
if (loader->type != VIR_DOMAIN_LOADER_TYPE_PFLASH) {
|
||||
VIR_DEBUG("Ignoring legacy entries for '%s' loader",
|
||||
virDomainLoaderTypeToString(loader->type));
|
||||
return 0;
|
||||
return 1;
|
||||
}
|
||||
|
||||
if (loader->stateless == VIR_TRISTATE_BOOL_YES) {
|
||||
VIR_DEBUG("Ignoring legacy entries for stateless loader");
|
||||
return 0;
|
||||
return 1;
|
||||
}
|
||||
|
||||
if (loader->format != VIR_STORAGE_FILE_RAW) {
|
||||
|
Loading…
Reference in New Issue
Block a user