2.3.56 FSCTL_QUERY_FILE_REGIONS Reply
The FSCTL_QUERY_FILE_REGIONS reply message returns the results of the FSCTL_QUERY_FILE_REGIONS Request as a variably sized data element, FILE_REGION_OUTPUT, which contains one or more FILE_REGION_INFO elements that contain the ranges computed as a result of the desired usage.
A FILE_REGION_OUTPUT data element is as follows.
|
|
|
|
|
|
|
|
|
|
1 |
|
|
|
|
|
|
|
|
|
2 |
|
|
|
|
|
|
|
|
|
3 |
|
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Flags |
|||||||||||||||||||||||||||||||
TotalRegionEntryCount |
|||||||||||||||||||||||||||||||
RegionEntryCount |
|||||||||||||||||||||||||||||||
Reserved |
|||||||||||||||||||||||||||||||
Region (variable) |
|||||||||||||||||||||||||||||||
... |
|||||||||||||||||||||||||||||||
... |
Flags (4 bytes): A 32-bit unsigned integer that indicates the flags for this operation. No flags are currently defined, thus this field SHOULD be set to 0x00000000 and MUST be ignored.
TotalRegionEntryCount (4 bytes): A 32-bit unsigned integer that indicates the total number of regions that could be returned.
RegionEntryCount (4 bytes): A 32-bit unsigned integer that indicates the number of regions that were actually returned and which are contained in this structure.
Reserved (4 bytes): A 32-bit unsigned integer that is reserved. This field SHOULD be set to 0x00000000 and MUST be ignored.
Region (variable): One or more FILE_REGION_INFO structures, as specified in section 2.3.56.1, that contain information on the desired ranges based on the desired usage indicated by the DesiredUsage field.
This message returns a status code as specified in section 2.2. Upon success, the status code returned by the function that processes this FSCTL is STATUS_SUCCESS. The most common error codes are listed in the following table.
Error code |
Meaning |
---|---|
STATUS_BUFFER_TOO_SMALL 0xC0000023 |
The input buffer is too small to contain a FILE_REGION_INPUT structure, or the output buffer is too small to contain a FILE_REGION_OUTPUT structure. |
STATUS_BUFFER_OVERFLOW 0x80000005 |
The output buffer was filled before all the desired regions for this file were returned. |
STATUS_INVALID_PARAMETER 0xC000000D |
A specified file region is invalid, or the specified desired usage flag is invalid, or the given handle is not for a file (but for a directory or volume instead). |