Share via


FSSCTL_FLUSH_BUFFERS (Compact 2013)

3/26/2014

This I/O control flushes all buffers in a specified file system.

Syntax

BOOL DeviceIoControl(
    HANDLE hDevice,           // handle to device
    DWORD dwIoControlCode,    // use FSCTL_FLUSH_BUFFERS
    LPVOID lpInBuffer,        // pointer to input buffer
    DWORD nInBufferSize,      // input buffer size
    LPVOID lpOutBuffer,       // pointer to output buffer
    DWORD nOutBufferSize,     // output buffer size
    LPDWORD lpBytesReturned,  // number of bytes returned
    OVERLAPPED lpOverlapped   // pointer to OVERLAPPED structure
);

Parameters

  • pszRoot
    Path of the file system to be flushed. The backslash (\) indicates the root of the file system. If this value is set to NULL, the file system is the object store, and the registry and databases are flushed, along with the object store.
  • dwIoControlCode
    Set to FSSCTL_FLUSH_BUFFERS.
  • lpInBuf
    Not used. Set to NULL.
  • nInBufSize
    Not used. Set to zero.
  • lpOutBuf
    Not used. Set to NULL.
  • nOutBufSize
    Not used. Set to zero.
  • lpBytesReturned
    Not used.

Return Values

If the operation succeeds, the DeviceIoControl function returns a nonzero value. If the operation fails, DeviceIoControl returns zero. For extended error information, call GetLastError.

Requirements

Header

fsioctl.h

See Also

Reference

FS I/O Controls

Other Resources

DeviceIoControl