[Wine-patches] [eterwine 2/3] mountmgr: Fix a regression.
Alexander Morozov
amorozov на etersoft.ru
Вт Май 15 20:05:48 MSK 2012
---
dlls/mountmgr.sys/usbhub.c | 21 +++++++--------------
1 file changed, 7 insertions(+), 14 deletions(-)
diff --git a/dlls/mountmgr.sys/usbhub.c b/dlls/mountmgr.sys/usbhub.c
index 533c298..d9475aa 100644
--- a/dlls/mountmgr.sys/usbhub.c
+++ b/dlls/mountmgr.sys/usbhub.c
@@ -263,12 +263,9 @@ static NTSTATUS get_node_conn_info( struct DeviceInstance *inst, void *buff,
conn_info->CurrentConfigurationValue = config;
libusb_close( husb );
}
- if (!ret)
- {
- conn_info->ConnectionStatus = 1;
- *outsize = sizeof(*conn_info);
- status = STATUS_SUCCESS;
- }
+ conn_info->ConnectionStatus = 1;
+ *outsize = sizeof(*conn_info);
+ status = STATUS_SUCCESS;
break;
}
}
@@ -295,24 +292,20 @@ static NTSTATUS get_node_conn_info( struct DeviceInstance *inst, void *buff,
if (++index == conn_info->ConnectionIndex)
{
usb_dev_handle *husb;
- int ret = -1;
memcpy( &conn_info->DeviceDescriptor, &dev->descriptor,
sizeof(USB_DEVICE_DESCRIPTOR) );
husb = usb_open( inst->dev );
if (husb)
{
- ret = usb_control_msg( husb, 1 << 7, USB_REQ_GET_CONFIGURATION,
+ usb_control_msg( husb, 1 << 7, USB_REQ_GET_CONFIGURATION,
0, 0, (char *)&conn_info->CurrentConfigurationValue,
sizeof(UCHAR), 0 );
usb_close( husb );
}
- if (ret >= 0)
- {
- conn_info->ConnectionStatus = 1;
- *outsize = sizeof(*conn_info);
- status = STATUS_SUCCESS;
- }
+ conn_info->ConnectionStatus = 1;
+ *outsize = sizeof(*conn_info);
+ status = STATUS_SUCCESS;
break;
}
return status;
--
1.7.9.7
Подробная информация о списке рассылки Wine-patches