mirror of
				https://github.com/winfsp/winfsp.git
				synced 2025-11-04 04:58:05 -06:00 
			
		
		
		
	sys: IRP_MJ_CREATE
This commit is contained in:
		@@ -133,6 +133,8 @@ typedef struct
 | 
			
		||||
        {
 | 
			
		||||
            UINT64 UserContext;         /* user context attached to an open file (unique file id) */
 | 
			
		||||
            UINT64 UserContext2;        /* user context attached to a kernel file object */
 | 
			
		||||
            UINT16 SecurityDescriptor;  /* security descriptor for existing files (offset within Buffer) */
 | 
			
		||||
            UINT16 SecurityDescriptorSize;  /* security descriptor size */
 | 
			
		||||
        } Create;
 | 
			
		||||
    } Rsp;
 | 
			
		||||
    FSP_FSCTL_DECLSPEC_ALIGN UINT8 Buffer[];
 | 
			
		||||
 
 | 
			
		||||
@@ -14,6 +14,8 @@ static NTSTATUS FspFsvolCreate(
 | 
			
		||||
    PDEVICE_OBJECT DeviceObject, PIRP Irp, PIO_STACK_LOCATION IrpSp);
 | 
			
		||||
FSP_IOPREP_DISPATCH FspFsvolCreatePrepare;
 | 
			
		||||
FSP_IOCMPL_DISPATCH FspFsvolCreateComplete;
 | 
			
		||||
static VOID FspFsvolCreateClose(
 | 
			
		||||
    PIRP Irp, const FSP_FSCTL_TRANSACT_RSP *Response);
 | 
			
		||||
FSP_DRIVER_DISPATCH FspCreate;
 | 
			
		||||
 | 
			
		||||
#ifdef ALLOC_PRAGMA
 | 
			
		||||
@@ -22,6 +24,7 @@ FSP_DRIVER_DISPATCH FspCreate;
 | 
			
		||||
#pragma alloc_text(PAGE, FspFsvolCreate)
 | 
			
		||||
#pragma alloc_text(PAGE, FspFsvolCreatePrepare)
 | 
			
		||||
#pragma alloc_text(PAGE, FspFsvolCreateComplete)
 | 
			
		||||
#pragma alloc_text(PAGE, FspFsvolCreateClose)
 | 
			
		||||
#pragma alloc_text(PAGE, FspCreate)
 | 
			
		||||
#endif
 | 
			
		||||
 | 
			
		||||
@@ -285,6 +288,8 @@ static NTSTATUS FspFsvolCreate(
 | 
			
		||||
            goto exit;
 | 
			
		||||
        }
 | 
			
		||||
 | 
			
		||||
        FileObject->FsContext = FsContext;
 | 
			
		||||
 | 
			
		||||
        Result = STATUS_PENDING;
 | 
			
		||||
 | 
			
		||||
    exit:;
 | 
			
		||||
@@ -302,7 +307,8 @@ NTSTATUS FspFsvolCreatePrepare(
 | 
			
		||||
{
 | 
			
		||||
    FSP_ENTER_IOP(PAGED_CODE());
 | 
			
		||||
 | 
			
		||||
    FSP_FSVOL_DEVICE_EXTENSION *FsvolDeviceExtension = FspFsvolDeviceExtension(IrpSp->DeviceObject);
 | 
			
		||||
    PDEVICE_OBJECT DeviceObject = IrpSp->DeviceObject;
 | 
			
		||||
    FSP_FSVOL_DEVICE_EXTENSION *FsvolDeviceExtension = FspFsvolDeviceExtension(DeviceObject);
 | 
			
		||||
    ASSERT(FspFsvolDeviceExtensionKind == FsvolDeviceExtension->Base.Kind);
 | 
			
		||||
 | 
			
		||||
    /* it is not necessary to retain the FsvrtDeviceObject; our callers have already done so */
 | 
			
		||||
@@ -342,6 +348,12 @@ VOID FspFsvolCreateComplete(
 | 
			
		||||
        IrpSp->FileObject, IrpSp->FileObject->RelatedFileObject, IrpSp->FileObject->FileName);
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
static VOID FspFsvolCreateClose(
 | 
			
		||||
    PIRP Irp, const FSP_FSCTL_TRANSACT_RSP *Response)
 | 
			
		||||
{
 | 
			
		||||
    PAGED_CODE();
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
NTSTATUS FspCreate(
 | 
			
		||||
    PDEVICE_OBJECT DeviceObject, PIRP Irp)
 | 
			
		||||
{
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user