ntoskrnl: Do not destroy the device list in enumerate_new_device().
Signed-off-by: Zebediah Figura <z.figura12@gmail.com> Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
parent
cd27f3ca00
commit
cb79644199
|
@ -336,7 +336,6 @@ static void enumerate_new_device( DEVICE_OBJECT *device, HDEVINFO set )
|
|||
&& !SetupDiOpenDeviceInfoW( set, device_instance_id, NULL, 0, &sp_device ))
|
||||
{
|
||||
ERR("Failed to create or open device %s, error %#x.\n", debugstr_w(device_instance_id), GetLastError());
|
||||
SetupDiDestroyDeviceInfoList( set );
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -353,10 +352,7 @@ static void enumerate_new_device( DEVICE_OBJECT *device, HDEVINFO set )
|
|||
}
|
||||
|
||||
if (need_driver && !install_device_driver( device, set, &sp_device ))
|
||||
{
|
||||
SetupDiDestroyDeviceInfoList( set );
|
||||
return;
|
||||
}
|
||||
|
||||
start_device( device, set, &sp_device );
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue