Skip to content
Snippets Groups Projects
Commit 01c7ee2f authored by Marcus Meissner's avatar Marcus Meissner Committed by Alexandre Julliard
Browse files

Allocate a DOS handle if we open a normal file with LZOpenFile16.

parent 6e953990
No related branches found
No related tags found
No related merge requests found
......@@ -540,7 +540,14 @@ static LPSTR LZEXPAND_MangleName( LPCSTR fn )
*/
HFILE16 WINAPI LZOpenFile16( LPCSTR fn, LPOFSTRUCT ofs, UINT16 mode )
{
return LZOpenFile32A( fn, ofs, mode );
HFILE32 hfret;
hfret = LZOpenFile32A( fn, ofs, mode );
/* return errors and LZ handles unmodified */
if (IS_LZ_HANDLE(hfret) || (hfret>=0xfff0) || (hfret<=0))
return hfret;
/* but allocate a dos handle for 'normal' files */
return FILE_AllocDosHandle(hfret);
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment