eject: Enable compilation with long types.
Signed-off-by: Eric Pouech <eric.pouech@gmail.com> Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
parent
a7f8adb5e3
commit
ed875d65e4
|
@ -1,4 +1,3 @@
|
||||||
EXTRADEFS = -DWINE_NO_LONG_TYPES
|
|
||||||
MODULE = eject.exe
|
MODULE = eject.exe
|
||||||
|
|
||||||
EXTRADLLFLAGS = -mconsole
|
EXTRADLLFLAGS = -mconsole
|
||||||
|
|
|
@ -70,16 +70,16 @@ static BOOL eject_cd( WCHAR drive )
|
||||||
WINE_TRACE( "ejecting %c:\n", (char)drive );
|
WINE_TRACE( "ejecting %c:\n", (char)drive );
|
||||||
|
|
||||||
if (!DeviceIoControl( handle, FSCTL_DISMOUNT_VOLUME, NULL, 0, NULL, 0, &result, NULL ))
|
if (!DeviceIoControl( handle, FSCTL_DISMOUNT_VOLUME, NULL, 0, NULL, 0, &result, NULL ))
|
||||||
WINE_WARN( "FSCTL_DISMOUNT_VOLUME failed with err %d\n", GetLastError() );
|
WINE_WARN( "FSCTL_DISMOUNT_VOLUME failed with err %ld\n", GetLastError() );
|
||||||
|
|
||||||
removal.PreventMediaRemoval = FALSE;
|
removal.PreventMediaRemoval = FALSE;
|
||||||
if (!DeviceIoControl( handle, IOCTL_STORAGE_MEDIA_REMOVAL, &removal, sizeof(removal), NULL, 0, &result, NULL ))
|
if (!DeviceIoControl( handle, IOCTL_STORAGE_MEDIA_REMOVAL, &removal, sizeof(removal), NULL, 0, &result, NULL ))
|
||||||
WINE_WARN( "IOCTL_STORAGE_MEDIA_REMOVAL failed with err %d\n", GetLastError() );
|
WINE_WARN( "IOCTL_STORAGE_MEDIA_REMOVAL failed with err %ld\n", GetLastError() );
|
||||||
|
|
||||||
if (!unmount_only)
|
if (!unmount_only)
|
||||||
{
|
{
|
||||||
if (!DeviceIoControl( handle, IOCTL_STORAGE_EJECT_MEDIA, NULL, 0, NULL, 0, &result, NULL ))
|
if (!DeviceIoControl( handle, IOCTL_STORAGE_EJECT_MEDIA, NULL, 0, NULL, 0, &result, NULL ))
|
||||||
WINE_WARN( "IOCTL_STORAGE_EJECT_MEDIA failed with err %d\n", GetLastError() );
|
WINE_WARN( "IOCTL_STORAGE_EJECT_MEDIA failed with err %ld\n", GetLastError() );
|
||||||
}
|
}
|
||||||
|
|
||||||
CloseHandle( handle );
|
CloseHandle( handle );
|
||||||
|
|
Loading…
Reference in New Issue