winebus.sys: Don't enter critical section in bus_find_unix_device.
Callers are already holding it. Signed-off-by: Rémi Bernon <rbernon@codeweavers.com> Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
parent
cf464a4d0b
commit
2c0da82050
|
@ -309,20 +309,11 @@ static DEVICE_OBJECT *bus_create_hid_device(struct device_desc *desc, struct uni
|
|||
static DEVICE_OBJECT *bus_find_unix_device(struct unix_device *unix_device)
|
||||
{
|
||||
struct device_extension *ext;
|
||||
DEVICE_OBJECT *ret = NULL;
|
||||
|
||||
RtlEnterCriticalSection(&device_list_cs);
|
||||
LIST_FOR_EACH_ENTRY(ext, &device_list, struct device_extension, entry)
|
||||
{
|
||||
if (ext->unix_device == unix_device)
|
||||
{
|
||||
ret = ext->device;
|
||||
break;
|
||||
}
|
||||
}
|
||||
RtlLeaveCriticalSection(&device_list_cs);
|
||||
if (ext->unix_device == unix_device) return ext->device;
|
||||
|
||||
return ret;
|
||||
return NULL;
|
||||
}
|
||||
|
||||
static void bus_unlink_hid_device(DEVICE_OBJECT *device)
|
||||
|
|
Loading…
Reference in New Issue