Bewerken

Delen via


PUNLOCK_ROUTINE callback function (ntifs.h)

A filter (legacy filter or minifilter) can register a PUNLOCK_ROUTINE-typed routine as the filter's UnlockRoutine callback routine for a FILE_LOCK structure.

Syntax

PUNLOCK_ROUTINE PunlockRoutine;

void PunlockRoutine(
  PVOID Context,
  PFILE_LOCK_INFO FileLockInfo
)
{...}

Parameters

Context

[in] Context pointer that was passed to FltProcessFileLock or FsRtlProcessFileLock.

FileLockInfo

Opaque pointer to the FILE_LOCK_INFO structure for the byte-range lock.

Return value

None

Remarks

A filter (legacy filter or minifilter) can optionally specify a PUNLOCK_ROUTINE-typed routine as the filter's UnlockRoutine callback for a byte-range file lock.

If the filter specifies an UnlockRoutine routine for a FILE_LOCK structure, this routine is called when the lock is removed from a locked byte range in a file.

A minifilter specifies this routine by passing a pointer to the routine as the UnlockRoutine parameter for FltAllocateFileLock.

A legacy filter specifies this routine by passing a pointer to the routine as the UnlockRoutine parameter for FsRtlAllocateFileLock or FsRtlInitializeFileLock.

Requirements

Requirement Value
Header ntifs.h
IRQL IRQL <= APC_LEVEL

See also

FltAllocateFileLock

FltCheckLockForReadAccess

FltCheckLockForWriteAccess

FltFreeFileLock

FltInitializeFileLock

FltProcessFileLock

FltUninitializeFileLock

FsRtlAllocateFileLock

FsRtlCheckLockForReadAccess

FsRtlCheckLockForWriteAccess

FsRtlFreeFileLock

FsRtlInitializeFileLock

FsRtlProcessFileLock

FsRtlUninitializeFileLock

IRP_MJ_LOCK_CONTROL

PCOMPLETE_LOCK_IRP_ROUTINE

PFLT_COMPLETE_LOCK_CALLBACK_DATA_ROUTINE