krnl386.exe16: Do not reassign default handles after they got closed.

Sebastian Lackner sebastian at fds-team.de
Tue Apr 5 10:58:17 CDT 2016


From: Michael Müller <michael at fds-team.de>

Signed-off-by: Michael Müller <michael at fds-team.de>
Signed-off-by: Sebastian Lackner <sebastian at fds-team.de>
---
 dlls/krnl386.exe16/file.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/dlls/krnl386.exe16/file.c b/dlls/krnl386.exe16/file.c
index b66b753..9b720ef 100644
--- a/dlls/krnl386.exe16/file.c
+++ b/dlls/krnl386.exe16/file.c
@@ -363,7 +363,7 @@ HFILE16 WINAPI _lclose16( HFILE16 hFile )
     }
     TRACE("%d (handle32=%p)\n", hFile, dos_handles[hFile] );
     CloseHandle( dos_handles[hFile] );
-    dos_handles[hFile] = 0;
+    dos_handles[hFile] = (hFile < 5) ? INVALID_HANDLE_VALUE : 0;
     return 0;
 }
 
-- 
2.7.1



More information about the wine-patches mailing list