Coverity #857: Fix resource leak in error path by freeing earlier.
This commit is contained in:
parent
55f677d600
commit
1bc72dce5f
|
@ -1,3 +1,8 @@
|
|||
2006-03-09 Eric Anholt <anholt@FreeBSD.org>
|
||||
|
||||
* hw/xfree86/int10/generic.c: (xf86ExtendedInitInt10):
|
||||
Coverity #857: Fix resource leak in error path by freeing earlier.
|
||||
|
||||
2006-03-09 Eric Anholt <anholt@FreeBSD.org>
|
||||
|
||||
* hw/xfree86/parser/Keyboard.c: (xf86parseKeyboardSection):
|
||||
|
|
|
@ -232,6 +232,8 @@ xf86ExtendedInitInt10(int entityIndex, int Flags)
|
|||
} else
|
||||
location_type = pEnt->location.type;
|
||||
|
||||
xfree(pEnt);
|
||||
|
||||
switch (location_type) {
|
||||
case BUS_PCI:
|
||||
vbiosMem = (unsigned char *)base + bios_location;
|
||||
|
@ -263,7 +265,6 @@ xf86ExtendedInitInt10(int entityIndex, int Flags)
|
|||
default:
|
||||
goto error1;
|
||||
}
|
||||
xfree(pEnt);
|
||||
pInt->BIOSseg = V_BIOS >> 4;
|
||||
pInt->num = 0xe6;
|
||||
LockLegacyVGA(pInt, &vga);
|
||||
|
|
Loading…
Reference in New Issue
Block a user