kernel32 actually already assumes this.
Signed-off-by: Zebediah Figura zfigura@codeweavers.com --- dlls/mountmgr.sys/mountmgr.c | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-)
diff --git a/dlls/mountmgr.sys/mountmgr.c b/dlls/mountmgr.sys/mountmgr.c index 3331eedf8d5..dd3a3932b40 100644 --- a/dlls/mountmgr.sys/mountmgr.c +++ b/dlls/mountmgr.sys/mountmgr.c @@ -311,6 +311,11 @@ static NTSTATUS query_unix_drive( void *buff, SIZE_T insize,
input = NULL; output = buff; + output->size = size; + output->letter = letter; + output->type = type; + output->mount_point_offset = 0; + output->device_offset = 0;
if (size > outsize) { @@ -328,9 +333,7 @@ static NTSTATUS query_unix_drive( void *buff, SIZE_T insize, status = STATUS_MORE_ENTRIES; goto done; } - output->size = size; - output->letter = letter; - output->type = type; + ptr = (char *)(output + 1);
if (mount_point)
STATUS_MORE_ENTRIES is meant for enumeration APIs like NtQueryDirectoryFile(); we are not enumerating anything here.
Signed-off-by: Zebediah Figura zfigura@codeweavers.com --- dlls/mountmgr.sys/mountmgr.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/dlls/mountmgr.sys/mountmgr.c b/dlls/mountmgr.sys/mountmgr.c index dd3a3932b40..222395fadf9 100644 --- a/dlls/mountmgr.sys/mountmgr.c +++ b/dlls/mountmgr.sys/mountmgr.c @@ -330,7 +330,7 @@ static NTSTATUS query_unix_drive( void *buff, SIZE_T insize, output->type = type; iosb->Information = FIELD_OFFSET( struct mountmgr_unix_drive, type ) + sizeof(output->type); } - status = STATUS_MORE_ENTRIES; + status = STATUS_BUFFER_OVERFLOW; goto done; }