mirror of https://gitee.com/openkylin/qemu.git
s390: Plug memory leak on s390_pci_generate_event() error path
Signed-off-by: Markus Armbruster <armbru@redhat.com> Signed-off-by: Cornelia Huck <cornelia.huck@de.ibm.com>
This commit is contained in:
parent
16017c4854
commit
b7022d9ac6
|
@ -187,7 +187,7 @@ S390PCIBusDevice *s390_pci_find_dev_by_fh(uint32_t fh)
|
|||
static void s390_pci_generate_event(uint8_t cc, uint16_t pec, uint32_t fh,
|
||||
uint32_t fid, uint64_t faddr, uint32_t e)
|
||||
{
|
||||
SeiContainer *sei_cont = g_malloc0(sizeof(SeiContainer));
|
||||
SeiContainer *sei_cont;
|
||||
S390pciState *s = S390_PCI_HOST_BRIDGE(
|
||||
object_resolve_path(TYPE_S390_PCI_HOST_BRIDGE, NULL));
|
||||
|
||||
|
@ -195,6 +195,7 @@ static void s390_pci_generate_event(uint8_t cc, uint16_t pec, uint32_t fh,
|
|||
return;
|
||||
}
|
||||
|
||||
sei_cont = g_malloc0(sizeof(SeiContainer));
|
||||
sei_cont->fh = fh;
|
||||
sei_cont->fid = fid;
|
||||
sei_cont->cc = cc;
|
||||
|
|
Loading…
Reference in New Issue