mirror of
https://github.com/reactos/reactos.git
synced 2024-12-28 18:15:11 +00:00
[NTFS]
Handle IRP_MJ_DIRECTORY_CONTROL with the dispatch routine svn path=/trunk/; revision=67615
This commit is contained in:
parent
8426d2f96e
commit
8ddf736b58
4 changed files with 20 additions and 40 deletions
|
@ -436,52 +436,30 @@ NtfsQueryDirectory(PNTFS_IRP_CONTEXT IrpContext)
|
|||
|
||||
|
||||
NTSTATUS
|
||||
NTAPI
|
||||
NtfsFsdDirectoryControl(PDEVICE_OBJECT DeviceObject,
|
||||
PIRP Irp)
|
||||
NtfsDirectoryControl(PNTFS_IRP_CONTEXT IrpContext)
|
||||
{
|
||||
PNTFS_IRP_CONTEXT IrpContext = NULL;
|
||||
NTSTATUS Status = STATUS_UNSUCCESSFUL;
|
||||
|
||||
DPRINT1("NtfsDirectoryControl() called\n");
|
||||
|
||||
FsRtlEnterFileSystem();
|
||||
ASSERT(DeviceObject);
|
||||
ASSERT(Irp);
|
||||
|
||||
NtfsIsIrpTopLevel(Irp);
|
||||
|
||||
IrpContext = NtfsAllocateIrpContext(DeviceObject, Irp);
|
||||
if (IrpContext)
|
||||
switch (IrpContext->MinorFunction)
|
||||
{
|
||||
switch (IrpContext->MinorFunction)
|
||||
{
|
||||
case IRP_MN_QUERY_DIRECTORY:
|
||||
Status = NtfsQueryDirectory(IrpContext);
|
||||
break;
|
||||
case IRP_MN_QUERY_DIRECTORY:
|
||||
Status = NtfsQueryDirectory(IrpContext);
|
||||
break;
|
||||
|
||||
case IRP_MN_NOTIFY_CHANGE_DIRECTORY:
|
||||
DPRINT1("IRP_MN_NOTIFY_CHANGE_DIRECTORY\n");
|
||||
Status = STATUS_NOT_IMPLEMENTED;
|
||||
break;
|
||||
case IRP_MN_NOTIFY_CHANGE_DIRECTORY:
|
||||
DPRINT1("IRP_MN_NOTIFY_CHANGE_DIRECTORY\n");
|
||||
Status = STATUS_NOT_IMPLEMENTED;
|
||||
break;
|
||||
|
||||
default:
|
||||
Status = STATUS_INVALID_DEVICE_REQUEST;
|
||||
break;
|
||||
}
|
||||
default:
|
||||
Status = STATUS_INVALID_DEVICE_REQUEST;
|
||||
break;
|
||||
}
|
||||
else
|
||||
Status = STATUS_INSUFFICIENT_RESOURCES;
|
||||
|
||||
Irp->IoStatus.Status = Status;
|
||||
Irp->IoStatus.Information = 0;
|
||||
IoCompleteRequest(Irp, IO_NO_INCREMENT);
|
||||
IrpContext->Irp->IoStatus.Information = 0;
|
||||
|
||||
if (IrpContext)
|
||||
ExFreePoolWithTag(IrpContext, 'PRIN');
|
||||
|
||||
IoSetTopLevelIrp(NULL);
|
||||
FsRtlExitFileSystem();
|
||||
return Status;
|
||||
}
|
||||
|
||||
|
|
|
@ -72,6 +72,10 @@ NtfsFsdDispatch(PDEVICE_OBJECT DeviceObject,
|
|||
case IRP_MJ_QUERY_INFORMATION:
|
||||
Status = NtfsQueryInformation(IrpContext);
|
||||
break;
|
||||
|
||||
case IRP_MJ_DIRECTORY_CONTROL:
|
||||
Status = NtfsDirectoryControl(IrpContext);
|
||||
break;
|
||||
}
|
||||
}
|
||||
else
|
||||
|
|
|
@ -126,7 +126,7 @@ NtfsInitializeFunctionPointers(PDRIVER_OBJECT DriverObject)
|
|||
DriverObject->MajorFunction[IRP_MJ_QUERY_INFORMATION] = NtfsFsdDispatch;
|
||||
DriverObject->MajorFunction[IRP_MJ_QUERY_VOLUME_INFORMATION] = NtfsFsdDispatch;
|
||||
DriverObject->MajorFunction[IRP_MJ_SET_VOLUME_INFORMATION] = NtfsFsdDispatch;
|
||||
DriverObject->MajorFunction[IRP_MJ_DIRECTORY_CONTROL] = NtfsFsdDirectoryControl;
|
||||
DriverObject->MajorFunction[IRP_MJ_DIRECTORY_CONTROL] = NtfsFsdDispatch;
|
||||
DriverObject->MajorFunction[IRP_MJ_FILE_SYSTEM_CONTROL] = NtfsFsdFileSystemControl;
|
||||
DriverObject->MajorFunction[IRP_MJ_DEVICE_CONTROL] = NtfsFsdDeviceControl;
|
||||
|
||||
|
|
|
@ -541,10 +541,8 @@ NtfsFsdDeviceControl(PDEVICE_OBJECT DeviceObject,
|
|||
|
||||
/* dirctl.c */
|
||||
|
||||
DRIVER_DISPATCH NtfsFsdDirectoryControl;
|
||||
NTSTATUS NTAPI
|
||||
NtfsFsdDirectoryControl(PDEVICE_OBJECT DeviceObject,
|
||||
PIRP Irp);
|
||||
NTSTATUS
|
||||
NtfsDirectoryControl(PNTFS_IRP_CONTEXT IrpContext);
|
||||
|
||||
|
||||
/* dispatch.c */
|
||||
|
|
Loading…
Reference in a new issue