mirror of
https://github.com/winfsp/winfsp.git
synced 2025-04-23 17:03:12 -05:00
sys: FSP_FSCTL_DEVICE_EXTENSION: add Resource
This commit is contained in:
parent
b4f64c3378
commit
a082cc1516
@ -95,6 +95,7 @@ static VOID FspFsctlDeviceDeleteObject(PDEVICE_OBJECT DeviceObject)
|
|||||||
{
|
{
|
||||||
PAGED_CODE();
|
PAGED_CODE();
|
||||||
|
|
||||||
|
ExDeleteResourceLite(&FspFsctlDeviceExtension(DeviceObject)->Resource);
|
||||||
IoDeleteDevice(DeviceObject);
|
IoDeleteDevice(DeviceObject);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -41,6 +41,8 @@ NTSTATUS DriverEntry(
|
|||||||
FSP_RETURN(IoDeleteDevice(FspFsctlDiskDeviceObject));
|
FSP_RETURN(IoDeleteDevice(FspFsctlDiskDeviceObject));
|
||||||
FspDeviceExtension(FspFsctlDiskDeviceObject)->Kind = FspFsctlDeviceExtensionKind;
|
FspDeviceExtension(FspFsctlDiskDeviceObject)->Kind = FspFsctlDeviceExtensionKind;
|
||||||
FspDeviceExtension(FspFsctlNetDeviceObject)->Kind = FspFsctlDeviceExtensionKind;
|
FspDeviceExtension(FspFsctlNetDeviceObject)->Kind = FspFsctlDeviceExtensionKind;
|
||||||
|
ExInitializeResourceLite(&FspFsctlDeviceExtension(FspFsctlDiskDeviceObject)->Resource);
|
||||||
|
ExInitializeResourceLite(&FspFsctlDeviceExtension(FspFsctlNetDeviceObject)->Resource);
|
||||||
|
|
||||||
/* setup the driver object */
|
/* setup the driver object */
|
||||||
DriverObject->DriverUnload = FspUnload;
|
DriverObject->DriverUnload = FspUnload;
|
||||||
|
@ -249,6 +249,7 @@ typedef struct
|
|||||||
typedef struct
|
typedef struct
|
||||||
{
|
{
|
||||||
FSP_DEVICE_EXTENSION Base;
|
FSP_DEVICE_EXTENSION Base;
|
||||||
|
ERESOURCE Resource;
|
||||||
} FSP_FSCTL_DEVICE_EXTENSION;
|
} FSP_FSCTL_DEVICE_EXTENSION;
|
||||||
typedef struct
|
typedef struct
|
||||||
{
|
{
|
||||||
|
@ -140,6 +140,7 @@ static NTSTATUS FspFsctlMountVolume(
|
|||||||
&FsvolDeviceObject);
|
&FsvolDeviceObject);
|
||||||
if (NT_SUCCESS(Result))
|
if (NT_SUCCESS(Result))
|
||||||
{
|
{
|
||||||
|
#pragma prefast(suppress:28175, "We are a filesystem: ok to access SectorSize")
|
||||||
FsvolDeviceObject->SectorSize =
|
FsvolDeviceObject->SectorSize =
|
||||||
FspFsvrtDeviceExtension(FsvrtDeviceObject)->VolumeParams.SectorSize;
|
FspFsvrtDeviceExtension(FsvrtDeviceObject)->VolumeParams.SectorSize;
|
||||||
FsvolDeviceExtension = FspFsvolDeviceExtension(FsvolDeviceObject);
|
FsvolDeviceExtension = FspFsvolDeviceExtension(FsvolDeviceObject);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user