mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2024-12-22 05:35:25 +00:00
qemu: Add missing early returns
In a couple of cases, we were reporting an error without actually terminating the parse process. Signed-off-by: Andrea Bolognani <abologna@redhat.com> Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
This commit is contained in:
parent
c472736062
commit
dcad670212
@ -439,6 +439,7 @@ qemuFirmwareMappingKernelParse(const char *path,
|
||||
virReportError(VIR_ERR_INTERNAL_ERROR,
|
||||
_("missing 'filename' in '%1$s'"),
|
||||
path);
|
||||
return -1;
|
||||
}
|
||||
|
||||
kernel->filename = g_strdup(filename);
|
||||
@ -458,6 +459,7 @@ qemuFirmwareMappingMemoryParse(const char *path,
|
||||
virReportError(VIR_ERR_INTERNAL_ERROR,
|
||||
_("missing 'filename' in '%1$s'"),
|
||||
path);
|
||||
return -1;
|
||||
}
|
||||
|
||||
memory->filename = g_strdup(filename);
|
||||
|
Loading…
Reference in New Issue
Block a user