FsRtlGetPerStreamContextPointer function

The FsRtlGetPerStreamContextPointer macro returns the file system's stream context for a file stream.

Syntax


PFSRTL_ADVANCED_FCB_HEADER FsRtlGetPerStreamContextPointer(
  _In_ PFILE_OBJECT FileObject
);

Parameters

FileObject [in]

Pointer to a file object for the file stream.

Return value

The FsRtlGetPerStreamContextPointer macro returns a pointer to the file system's stream context for the file stream represented by the given file object.

Remarks

File system filter drivers can use the FsRtlGetPerStreamContextPointer macro to obtain a stream context pointer for the file stream that is represented by a given file object. A stream context pointer is a pointer to the file system's stream context for the file stream. This pointer can be passed as a parameter to FsRtlInsertPerStreamContext, FsRtlLookupPerStreamContext, and FsRtlRemovePerStreamContext.

The stream context pointer points to a FSRTL_ADVANCED_FCB_HEADER structure that uniquely identifies the file stream to the file system. This structure is usually embedded in a stream context object, such as a file control block (FCB) or stream control block (SCB). When the file stream is opened, the file system stores a pointer to the FCB or SCB in the file object's FsContext member.

Note   The FsRtlGetPerStreamContextPointer macro can only be used on file systems that support advanced FCB headers.
 

For more information, see Tracking Per-Stream Context in a Legacy File System Filter Driver.

Requirements

Target platform

Version

The FsRtlGetPerStreamContextPointer macro is available on Microsoft Windows XP and later, and on the Update Rollup for Windows 2000 Service Pack 4 (SP4).

Header

Ntifs.h (include Ntifs.h)

IRQL

<= APC_LEVEL

See also

FSRTL_ADVANCED_FCB_HEADER
FsRtlInitPerStreamContext
FsRtlInsertPerStreamContext
FsRtlLookupPerStreamContext
FsRtlRemovePerStreamContext
FsRtlSetupAdvancedHeader
FsRtlSupportsPerStreamContexts
FsRtlTeardownPerStreamContexts

 

 

Send comments about this topic to Microsoft

Show: