fs: fully initialize _OVERLAPPED for win32

This commit is contained in:
Cory Fields authored and fanquake committed 2022-09-14 11:55:10 +01:00
1 parent 13fd9ee5c2
commit 02c9e56468
1 file changed
+1 -1
+1 -1
View File
@@ -126,7 +126,7 @@ bool FileLock::TryLock()
if (hFile == INVALID_HANDLE_VALUE) {
return false;
}
_OVERLAPPED overlapped = {0};
_OVERLAPPED overlapped = {};
if (!LockFileEx(hFile, LOCKFILE_EXCLUSIVE_LOCK | LOCKFILE_FAIL_IMMEDIATELY, 0, std::numeric_limits<DWORD>::max(), std::numeric_limits<DWORD>::max(), &overlapped)) {
reason = GetErrorReason();
return false;