krnl386.exe16: Do not reassign default handles after they got closed.
Sebastian Lackner
sebastian at fds-team.de
Mon Apr 18 04:29:29 CDT 2016
Based on a patch by Michael Müller.
Signed-off-by: Sebastian Lackner <sebastian at fds-team.de>
---
Fixes the first part of https://bugs.winehq.org/show_bug.cgi?id=19184.
The second part (return value of _lclose on a closed handle) will be fixed separately.
dlls/krnl386.exe16/file.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/dlls/krnl386.exe16/file.c b/dlls/krnl386.exe16/file.c
index b66b753..4e7f7c4 100644
--- a/dlls/krnl386.exe16/file.c
+++ b/dlls/krnl386.exe16/file.c
@@ -113,8 +113,7 @@ HFILE WINAPI Win32HandleToDosFileHandle( HANDLE handle )
if (!handle || (handle == INVALID_HANDLE_VALUE))
return HFILE_ERROR;
- FILE_InitProcessDosHandles();
- for (i = 0; i < DOS_TABLE_SIZE; i++)
+ for (i = 5; i < DOS_TABLE_SIZE; i++)
if (!dos_handles[i])
{
dos_handles[i] = handle;
--
2.7.1
More information about the wine-patches
mailing list