Rob Shearman : dsound: Implement QueryInterface for the class factory objects.

Alexandre Julliard julliard at wine.codeweavers.com
Mon Apr 30 07:11:20 CDT 2007


Module: wine
Branch: master
Commit: ade2984e0374852fef18836e9e78aa1713370a30
URL:    http://source.winehq.org/git/wine.git/?a=commit;h=ade2984e0374852fef18836e9e78aa1713370a30

Author: Rob Shearman <rob at codeweavers.com>
Date:   Sun Apr 29 17:44:36 2007 +0100

dsound: Implement QueryInterface for the class factory objects.

---

 dlls/dsound/dsound_main.c |   10 +++++++++-
 1 files changed, 9 insertions(+), 1 deletions(-)

diff --git a/dlls/dsound/dsound_main.c b/dlls/dsound/dsound_main.c
index 94d2122..1736fe3 100644
--- a/dlls/dsound/dsound_main.c
+++ b/dlls/dsound/dsound_main.c
@@ -439,9 +439,17 @@ static HRESULT WINAPI
 DSCF_QueryInterface(LPCLASSFACTORY iface, REFIID riid, LPVOID *ppobj)
 {
     IClassFactoryImpl *This = (IClassFactoryImpl *)iface;
-    FIXME("(%p, %s, %p) stub!\n", This, debugstr_guid(riid), ppobj);
+    TRACE("(%p, %s, %p)\n", This, debugstr_guid(riid), ppobj);
     if (ppobj == NULL)
         return E_POINTER;
+    if (IsEqualIID(riid, &IID_IUnknown) ||
+        IsEqualIID(riid, &IID_IClassFactory))
+    {
+        *ppobj = iface;
+        IUnknown_AddRef(iface);
+        return S_OK;
+    }
+    *ppobj = NULL;
     return E_NOINTERFACE;
 }
 




More information about the wine-cvs mailing list