OvmfPkg/QemuVideoDxe: don't leak descriptors returned by GetBarAttributes

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Laszlo Ersek <lersek@redhat.com>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>

git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@14877 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
Laszlo Ersek 2013-11-20 22:31:14 +00:00 committed by jljusten
parent a93b0f4549
commit 5cdb96fa0d
2 changed files with 5 additions and 0 deletions

View File

@ -305,6 +305,10 @@ QemuVideoControllerDriverStart (
DEBUG ((EFI_D_INFO, "QemuVideo: Using mmio bar @ 0x%lx\n",
MmioDesc->AddrRangeMin));
}
if (!EFI_ERROR (Status)) {
FreePool (MmioDesc);
}
}
//

View File

@ -72,6 +72,7 @@ QemuVideoCompleteModeData (
Mode->FrameBufferSize = Mode->FrameBufferSize * ((ModeData->ColorDepth + 7) / 8);
DEBUG ((EFI_D_INFO, "FrameBufferBase: 0x%x, FrameBufferSize: 0x%x\n", Mode->FrameBufferBase, Mode->FrameBufferSize));
FreePool (FrameBufDesc);
return EFI_SUCCESS;
}