summaryrefslogtreecommitdiffstats
path: root/OvmfPkg/VirtHstiDxe/QemuQ35.c
diff options
context:
space:
mode:
authorDoug Cook (WINDOWS) <dcook@microsoft.com>2024-11-30 17:32:03 -0800
committermergify[bot] <37929162+mergify[bot]@users.noreply.github.com>2024-12-17 19:01:48 +0000
commitd1fccbf494a4f38f803cb8288dd6b08ec7b98dcc (patch)
tree7b66fd05637e710b5212fda8aa7b320cceac40bd /OvmfPkg/VirtHstiDxe/QemuQ35.c
parent30c8a73850b478042cc8e208298f37084940b9e7 (diff)
downloadedk2-master.tar.gz
edk2-master.tar.bz2
edk2-master.zip
EmulatorPkg: spurious failure in WriteBlocks on X64HEADmaster
WinNtBlockIoWriteBlocks can spuriously fail on X64. This occurs because &BytesWritten is a `UINTN*` (i.e. `UINT64*`) but is cast to `LPDWORD` (i.e. `UINT32*`). Only the low 32 bits are initialized by WriteFile, so the high 32 bits are uninitialized. This means we will spuriously fail the `BytesWritten != BufferSize` test. This doesn't occur on X86-32 since UINTN is the same as DWORD in that case. Fix is to declare BytesWritten as DWORD to match the type expected by WriteFile. This also makes the cast unnecessary. Signed-off-by: Doug Cook <idigdoug@gmail.com>
Diffstat (limited to 'OvmfPkg/VirtHstiDxe/QemuQ35.c')
0 files changed, 0 insertions, 0 deletions