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

Alexandre Julliard julliard at winehq.org
Tue Apr 5 22:50:00 CDT 2016


Sebastian Lackner <sebastian at fds-team.de> writes:

> @@ -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;

This will cause functions that take default handles to not return the
correct errors. Is that really how it's supposed to work? What bug is
this for?

-- 
Alexandre Julliard
julliard at winehq.org



More information about the wine-devel mailing list