From: Alistair Leslie-Hughes leslie_alistair@hotmail.com
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=49615 --- dlls/mountmgr.sys/device.c | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-)
diff --git a/dlls/mountmgr.sys/device.c b/dlls/mountmgr.sys/device.c index 22c17025e87..d54dbbea3d6 100644 --- a/dlls/mountmgr.sys/device.c +++ b/dlls/mountmgr.sys/device.c @@ -899,8 +899,18 @@ static BOOL get_volume_device_info( struct volume *volume ) } else { - volume->fs_type = VOLUME_ReadFATSuperblock( handle, superblock ); - if (volume->fs_type == FS_UNKNOWN) volume->fs_type = VOLUME_ReadCDSuperblock( handle, superblock ); + if(GetLastError() == ERROR_NOT_READY) + { + TRACE( "%s: removable drive with no inserted media\n", debugstr_a(unix_device) ); + volume->fs_type = FS_UNKNOWN; + CloseHandle( handle ); + return TRUE; + } + else + { + volume->fs_type = VOLUME_ReadFATSuperblock( handle, superblock ); + if (volume->fs_type == FS_UNKNOWN) volume->fs_type = VOLUME_ReadCDSuperblock( handle, superblock ); + } }
TRACE( "%s: found fs type %d\n", debugstr_a(unix_device), volume->fs_type );