mirror of
https://github.com/reactos/reactos.git
synced 2025-04-26 08:30:21 +00:00
[kernel32]
- OpenFile: set the structure size after doing basic parameter checks - Fixes two kernel32 file tests svn path=/trunk/; revision=44394
This commit is contained in:
parent
17c8128475
commit
5b3aa0ee80
1 changed files with 2 additions and 2 deletions
|
@ -239,7 +239,6 @@ OpenFile(LPCSTR lpFileName,
|
||||||
return HFILE_ERROR;
|
return HFILE_ERROR;
|
||||||
}
|
}
|
||||||
|
|
||||||
lpReOpenBuff->cBytes = sizeof(OFSTRUCT);
|
|
||||||
lpReOpenBuff->nErrCode = 0;
|
lpReOpenBuff->nErrCode = 0;
|
||||||
|
|
||||||
if (uStyle & OF_REOPEN) lpFileName = lpReOpenBuff->szPathName;
|
if (uStyle & OF_REOPEN) lpFileName = lpReOpenBuff->szPathName;
|
||||||
|
@ -282,10 +281,11 @@ OpenFile(LPCSTR lpFileName,
|
||||||
return -1;
|
return -1;
|
||||||
|
|
||||||
default:
|
default:
|
||||||
|
lpReOpenBuff->cBytes = sizeof(OFSTRUCT);
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
lpReOpenBuff->cBytes = sizeof(OFSTRUCT);
|
||||||
if ((uStyle & OF_CREATE) == OF_CREATE)
|
if ((uStyle & OF_CREATE) == OF_CREATE)
|
||||||
{
|
{
|
||||||
DWORD Sharing;
|
DWORD Sharing;
|
||||||
|
|
Loading…
Reference in a new issue