Hi I’m on the development of a virtual file system driver. This driver allows the user-mode process to manage this virtual files. It is a virtual drive letter to file system. Take the example of the drive n: which are virtual file system
Problem:
When I use the API CreateFileMapping on a file loacted drive n:,
it return NULL with error code 993.
The file uc.c is exists and f not equal INVALID_HANDLE_VALUE but x is NULL with err=193
The file ui.c is size average 30 000 bytes f=CreateFile(“n:\ui.c”,GENERIC_READ,FILE_SHARE_READ,NULL,OPEN_EXISTING,FILE_ATTR IBUTE_NORMAL,NULL);
SetLastError(0);
HANDLE x=CreateFileMapping(f,NULL,PAGE_READONLY,0,200,NULL);
int err=GetLastError();
The virtual drive file system is created with line :
status=IoCreateDevice(DriverObject, sizeof (TPARAMVDF), &dn, FILE_DEVICE_DISK_FILE_SYSTEM, FILE_DEVICE_SECURE_OPEN, FALSE, &gvd);
IoRegisterFileSystem(gvd);