Juan Lang : setupapi: Implement SetupDiCreateDeviceInterfaceA on top of SetupDiCreateInterfaceW.
Alexandre Julliard
julliard at winehq.org
Mon Sep 24 08:08:00 CDT 2007
Module: wine
Branch: master
Commit: aa2b23cab5aeabc893d9d635848f7357064614e0
URL: http://source.winehq.org/git/wine.git/?a=commit;h=aa2b23cab5aeabc893d9d635848f7357064614e0
Author: Juan Lang <juan.lang at gmail.com>
Date: Fri Sep 21 11:34:30 2007 -0700
setupapi: Implement SetupDiCreateDeviceInterfaceA on top of SetupDiCreateInterfaceW.
---
dlls/setupapi/devinst.c | 18 ++++++++++++++++--
1 files changed, 16 insertions(+), 2 deletions(-)
diff --git a/dlls/setupapi/devinst.c b/dlls/setupapi/devinst.c
index 35d2b78..2129296 100644
--- a/dlls/setupapi/devinst.c
+++ b/dlls/setupapi/devinst.c
@@ -1767,12 +1767,26 @@ BOOL WINAPI SetupDiCreateDeviceInterfaceA(
DWORD CreationFlags,
PSP_DEVICE_INTERFACE_DATA DeviceInterfaceData)
{
+ BOOL ret;
+ LPWSTR ReferenceStringW = NULL;
+
TRACE("%p %p %s %s %08x %p\n", DeviceInfoSet, DeviceInfoData,
debugstr_guid(InterfaceClassGuid), debugstr_a(ReferenceString),
CreationFlags, DeviceInterfaceData);
- FIXME("stub\n");
- return FALSE;
+ if (ReferenceString)
+ {
+ ReferenceStringW = MultiByteToUnicode(ReferenceString, CP_ACP);
+ if (ReferenceStringW == NULL) return FALSE;
+ }
+
+ ret = SetupDiCreateDeviceInterfaceW(DeviceInfoSet, DeviceInfoData,
+ InterfaceClassGuid, ReferenceStringW, CreationFlags,
+ DeviceInterfaceData);
+
+ MyFree(ReferenceStringW);
+
+ return ret;
}
/***********************************************************************
More information about the wine-cvs
mailing list