ClfsReadRestartArea function

The ClfsReadRestartArea routine reads the restart record that was most recently written to a specified CLFS stream.

Syntax

CLFSUSER_API NTSTATUS ClfsReadRestartArea(
  PVOID     pvMarshalContext,
  PVOID     *ppvRestartBuffer,
  PULONG    pcbRestartBuffer,
  PCLFS_LSN plsn,
  PVOID     *ppvReadContext
);

Parameters

pvMarshalContext

A pointer to an opaque context that represents a marshalling area associated with a CLFS stream. The caller previously obtained this pointer by calling ClfsCreateMarshallingArea.

ppvRestartBuffer

A pointer to a variable that receives a pointer to the data buffer of the restart record.

pcbRestartBuffer

A pointer to a ULONG-typed variable that receives the size, in bytes, of the data buffer pointed to by pcbRestartBuffer. This is the length of the data buffer of the restart record.

plsn

A pointer to a CLFS_LSN structure that receives the LSN of the restart record that was read.

ppvReadContext

A pointer to a variable that receives a pointer to an opaque read context. The caller can pass this context to ClfsReadPreviousRestartArea or ClfsReadNextLogRecord. When the caller has finished using the read context, it must free the context by calling ClfsTerminateReadLog.

Return Value

ClfsReadRestartArea returns STATUS_SUCCESS if it succeeds; otherwise, it returns one of the error codes defined in Ntstatus.h.

Remarks

For an explanation of CLFS concepts and terminology, see Common Log File System.

For information about reading records from CLFS streams, see Reading Data Records from a CLFS Stream and Reading Restart Records from a CLFS Stream.

Read contexts are not thread-safe. Clients are responsible for serializing access to read contexts.

Requirements

   
Windows version Available in Windows Server 2003 R2, Windows Vista, and later versions of Windows.
Target Platform Desktop
Header wdm.h (include Wdm.h)
Library Clfs.lib
DLL Clfs.sys
IRQL "<= APC_LEVEL"

See Also

ClfsCreateMarshallingArea

ClfsReadNextLogRecord

ClfsReadPreviousRestartArea

ClfsTerminateReadLog