// ntifs.h
NTSTATUS FsRtlInsertPerStreamContext(
PFSRTL_ADVANCED_FCB_HEADER PerStreamContext,
[in] PFSRTL_PER_STREAM_CONTEXT Ptr
);
View the official Windows Driver Kit DDI reference
No description available.
The FsRtlInsertPerStreamContext routine associates a file system filter driver's per-stream context structure with a file stream.
PerStreamContext
Pointer to the FSRTL_ADVANCED_FCB_HEADER structure for the file stream. To get this pointer from a file object, use the FsRtlGetPerStreamContextPointer macro.
Ptr
[in]Pointer to a FSRTL_PER_STREAM_CONTEXT structure that the filter driver has allocated and initialized. To initialize this structure, use the FsRtlInitPerStreamContext macro.
FsRtlInsertPerStreamContext returns one of the following NTSTATUS values:
Return code | Description |
---|---|
STATUS_SUCCESS | The call to FsRtlInsertPerStreamContext was successful. |
STATUS_INVALID_DEVICE_REQUEST | The underlying file system does not support filter contexts. |
A file system filter driver calls FsRtlInsertPerStreamContext to associate its own per-stream context structure with a file stream. The per-stream context structure contains context information that the filter driver maintains for the file stream.
After the per-stream context structure has been associated with a file stream, it can be retrieved by calling FsRtlLookupPerStreamContext or removed by calling FsRtlRemovePerStreamContext.
For more information, see Tracking Per-Stream Context in a Legacy File System Filter Driver.
FsRtlGetPerStreamContextPointer
FsRtlSupportsPerStreamContexts
FsRtlTeardownPerStreamContexts