2013-09-28 11:39:51 +00:00
|
|
|
/*
|
|
|
|
* PROJECT: ReactOS api tests
|
|
|
|
* LICENSE: See COPYING in the top level directory
|
|
|
|
* PURPOSE: Test for NtCreateFile
|
|
|
|
* PROGRAMMER: Aleksandar Andrejevic <theflash AT sdf DOT lonestar DOT org>
|
|
|
|
*/
|
|
|
|
|
2017-12-02 20:05:46 +00:00
|
|
|
#include "precomp.h"
|
2013-09-28 11:39:51 +00:00
|
|
|
|
|
|
|
START_TEST(NtCreateFile)
|
|
|
|
{
|
|
|
|
NTSTATUS Status;
|
|
|
|
HANDLE FileHandle;
|
|
|
|
IO_STATUS_BLOCK StatusBlock;
|
|
|
|
|
|
|
|
Status = NtCreateFile(&FileHandle,
|
|
|
|
FILE_READ_DATA,
|
2018-04-03 21:13:17 +00:00
|
|
|
(POBJECT_ATTRIBUTES)(ULONG_PTR)0xCCCCCCCCCCCCCCCCULL,
|
2013-09-28 11:39:51 +00:00
|
|
|
&StatusBlock,
|
|
|
|
NULL,
|
|
|
|
FILE_ATTRIBUTE_NORMAL,
|
|
|
|
FILE_SHARE_READ,
|
|
|
|
FILE_OPEN_IF,
|
|
|
|
FILE_NON_DIRECTORY_FILE,
|
|
|
|
NULL,
|
|
|
|
0);
|
|
|
|
|
|
|
|
ok_hex(Status, STATUS_ACCESS_VIOLATION);
|
|
|
|
}
|