minor fix in SetupDiGetDeviceInstanceIdA
Modified: trunk/reactos/lib/setupapi/devinst.c
_____
Modified: trunk/reactos/lib/setupapi/devinst.c
--- trunk/reactos/lib/setupapi/devinst.c 2005-11-26 10:18:02 UTC
(rev 19622)
+++ trunk/reactos/lib/setupapi/devinst.c 2005-11-26 10:18:24 UTC
(rev 19623)
@@ -3493,7 +3493,7 @@
DeviceInstanceIdW,
DeviceInstanceIdSize,
RequiredSize);
- if (DeviceInstanceIdW != NULL)
+ if (ret && DeviceInstanceIdW != NULL)
{
if (WideCharToMultiByte(CP_ACP, 0, DeviceInstanceIdW, -1,
DeviceInstanceId, DeviceInstanceIdSize, NULL, NULL) ==
0)