FSDMGR_RemoveFileLock (Windows Embedded CE 6.0)
1/6/2010
Helper function provided by File System Disk Manager (FSDMGR) to simplify the implementation of the MyFSD_UnLockFileEx function in a file system driver (FSD).
Syntax
BOOL MyFSD_UnlockFileEx(
PACQUIREFILELOCKSTATE pAcquireFileLockState
PRELEASEFILELOCKSTATE pReleaseFileLockState
DWORD dwHandle,
DWORD dwReserved,
DWORD nNumberOfBytesToUnlockLow,
DWORD nNumberOfBytesToUnlockHigh,
LPOVERLAPPED lpOverlapped
);
Parameters
- pAcquireFileLockState
[in] Pointer to a PACQUIREFILELOCKSTATE in the calling FSD.
- pReleaseFileLockState
[in] Pointer to a PRELEASEFILELOCKSTATE in the calling FSD.
- pHandle
[in] Pointer to the value that an FSD passes to the FSDMGR_CreateFileHandle function when creating the file handle.
- dwReserved
Ignored. Set to zero
- nNumberOfBytesToUnlockLow
[in] Low-order portion of the length of the byte range to unlock.
- nNumberOfBytesToUnlockHigh
[in] High-order portion of the length of the byte range to unlock.
- lpOverlapped
[in] Pointer to an OVERLAPPED structure that is used with the unlock request. This structure contains the file offset of the beginning of the unlock range.
Return Value
Nonzero indicates that the lock was successfully removed. Zero indicates failure. To get extended error information, call GetLastError.
Remarks
The FSD can simply pass all parameters received by MyFSD_UnlockFileEx to this helper function with two helper function pointers, PACQUIREFILELOCKSTATE and PRELEASEFILELOCKSTATE, implemented by the FSD.
This function is a Lock Manager function provided by FSDMGR to assist FSDs with implementing the MyFSD_LockFileEx and the MyFSD_UnlockFileEx functions.
Requirements
Header | lockmgrhelp.h |
Library | Fsdmgr.lib |
Windows Embedded CE | Windows CE 5.0 and later |
See Also
Reference
FSDMGR Functions
FSD Functions
FSDMGR_CreateFileHandle
MyFSD_CreateFileW
MyFSD_FindFirstFileW