// ntifs.h
BOOLEAN CcIsThereDirtyDataEx(
[in] PVPB Vpb,
[in, optional] PULONG NumberOfDirtyPages
);
View the official Windows Driver Kit DDI referenceNo description available.
The CcIsThereDirtyDataEx routine determines whether a volume contains any files that have dirty data in the system cache.
Vpb [in]A pointer to a volume parameter block (VPB) for the volume.
NumberOfDirtyPages [in, optional]An optional pointer to an unsigned long buffer that receives the number of dirty pages on the volume (associated with the Vpb parameter).
The CcIsThereDirtyDataEx routine returns TRUE if the volume contains one or more cached files whose data has been modified in the cache, but not yet flushed to disk. Otherwise, this routine returns FALSE.
This routine will return TRUE if any dirty pages exist including temporary files (CcIsThereDirtyData ignores temporary files). It will also return TRUE if there is any data currently queued to the volume.