mmdevapi: Fix build with MSVC. (try 2)

Thomas Faber thomas.faber at reactos.org
Mon Sep 30 07:45:37 CDT 2013


Missed the header file, sorry.
-------------- next part --------------
From 498e37baf4d76bcd125e2a22d2bb34761872a7b5 Mon Sep 17 00:00:00 2001
From: Thomas Faber <thomas.faber at reactos.org>
Date: Mon, 30 Sep 2013 14:13:13 +0200
Subject: mmdevapi: Fix build with MSVC.

---
 dlls/mmdevapi/devenum.c  | 3 ++-
 dlls/mmdevapi/mmdevapi.h | 8 ++++----
 2 files changed, 6 insertions(+), 5 deletions(-)

diff --git a/dlls/mmdevapi/devenum.c b/dlls/mmdevapi/devenum.c
index 21a3530..eebf4ed 100644
--- a/dlls/mmdevapi/devenum.c
+++ b/dlls/mmdevapi/devenum.c
@@ -569,7 +569,8 @@ static HRESULT WINAPI MMDevice_Activate(IMMDevice *iface, REFIID riid, DWORD cls
             {
                 /* ::Load cannot assume the interface stays alive after the function returns,
                  * so just create the interface on the stack, saves a lot of complicated code */
-                IPropertyBagImpl bag = { { &PB_Vtbl }, This->devguid };
+                IPropertyBagImpl bag = { { &PB_Vtbl } };
+                bag.devguid = This->devguid;
                 hr = IPersistPropertyBag_Load(ppb, &bag.IPropertyBag_iface, NULL);
                 IPersistPropertyBag_Release(ppb);
                 if (FAILED(hr))
diff --git a/dlls/mmdevapi/mmdevapi.h b/dlls/mmdevapi/mmdevapi.h
index c511240..2a04780 100644
--- a/dlls/mmdevapi/mmdevapi.h
+++ b/dlls/mmdevapi/mmdevapi.h
@@ -41,18 +41,18 @@ typedef struct _DriverFuncs {
      * If multiple drivers think they are valid, they will return a
      * priority value reflecting the likelihood that they are actually
      * valid. See enum _DriverPriority. */
-    int WINAPI (*pGetPriority)(void);
+    int (WINAPI *pGetPriority)(void);
 
     /* ids gets an array of human-friendly endpoint names
      * keys gets an array of driver-specific stuff that is used
      *   in GetAudioEndpoint to identify the endpoint
      * it is the caller's responsibility to free both arrays, and
      *   all of the elements in both arrays with HeapFree() */
-    HRESULT WINAPI (*pGetEndpointIDs)(EDataFlow flow, WCHAR ***ids,
+    HRESULT (WINAPI *pGetEndpointIDs)(EDataFlow flow, WCHAR ***ids,
             GUID **guids, UINT *num, UINT *default_index);
-    HRESULT WINAPI (*pGetAudioEndpoint)(void *key, IMMDevice *dev,
+    HRESULT (WINAPI *pGetAudioEndpoint)(void *key, IMMDevice *dev,
             IAudioClient **out);
-    HRESULT WINAPI (*pGetAudioSessionManager)(IMMDevice *device,
+    HRESULT (WINAPI *pGetAudioSessionManager)(IMMDevice *device,
             IAudioSessionManager2 **out);
 } DriverFuncs;
 
-- 
1.7.11.msysgit.1


More information about the wine-patches mailing list