Alexandre Julliard : ole32: Use a dlldata. c file instead of maintaining the data manually.

Alexandre Julliard julliard at winehq.org
Tue Dec 2 11:01:51 CST 2008


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

Author: Alexandre Julliard <julliard at winehq.org>
Date:   Mon Dec  1 18:56:15 2008 +0100

ole32: Use a dlldata.c file instead of maintaining the data manually.

---

 dlls/ole32/Makefile.in       |    5 ++++-
 dlls/ole32/compobj_private.h |    3 +++
 dlls/ole32/oleproxy.c        |   21 +--------------------
 3 files changed, 8 insertions(+), 21 deletions(-)

diff --git a/dlls/ole32/Makefile.in b/dlls/ole32/Makefile.in
index e82b2ad..a38c965 100644
--- a/dlls/ole32/Makefile.in
+++ b/dlls/ole32/Makefile.in
@@ -1,4 +1,3 @@
-EXTRADEFS = -D_OLE32_ -DCOM_NO_WINDOWS_H
 TOPSRCDIR = @top_srcdir@
 TOPOBJDIR = ../..
 SRCDIR    = @srcdir@
@@ -6,6 +5,8 @@ VPATH     = @srcdir@
 MODULE    = ole32.dll
 IMPORTLIB = ole32
 IMPORTS   = uuid advapi32 user32 gdi32 rpcrt4 kernel32 ntdll
+EXTRADEFS = -D_OLE32_ -DCOM_NO_WINDOWS_H \
+    -DENTRY_PREFIX=OLE32_ -DPROXY_CLSID=CLSID_PSFactoryBuffer
 
 C_SRCS = \
 	antimoniker.c \
@@ -74,6 +75,8 @@ IDL_P_SRCS = \
 	ole32_oleidl.idl \
 	ole32_unknwn.idl
 
+EXTRA_OBJS = dlldata.o
+
 @MAKE_DLL_RULES@
 
 ole2nls.spec.o: ole2nls.spec version16.res
diff --git a/dlls/ole32/compobj_private.h b/dlls/ole32/compobj_private.h
index 4b88ad2..150c7c7 100644
--- a/dlls/ole32/compobj_private.h
+++ b/dlls/ole32/compobj_private.h
@@ -309,6 +309,9 @@ extern HINSTANCE OLE32_hInstance; /* FIXME: make static */
 
 #define WINE_CLSCTX_DONT_HOST   0x80000000
 
+/* from dlldata.c */
+extern HRESULT WINAPI OLE32_DllGetClassObject(REFCLSID rclsid, REFIID iid,LPVOID *ppv) DECLSPEC_HIDDEN;
+
 /* Exported non-interface Data Advise Holder functions */
 HRESULT DataAdviseHolder_OnConnect(IDataAdviseHolder *iface, IDataObject *pDelegate);
 void DataAdviseHolder_OnDisconnect(IDataAdviseHolder *iface);
diff --git a/dlls/ole32/oleproxy.c b/dlls/ole32/oleproxy.c
index 99a86f0..dfc3bc1 100644
--- a/dlls/ole32/oleproxy.c
+++ b/dlls/ole32/oleproxy.c
@@ -36,7 +36,6 @@
 #include "objbase.h"
 #include "ole2.h"
 #include "rpc.h"
-#include "rpcproxy.h"
 
 #include "compobj_private.h"
 #include "moniker.h"
@@ -46,23 +45,6 @@
 
 WINE_DEFAULT_DEBUG_CHANNEL(ole);
 
-static CStdPSFactoryBuffer PSFactoryBuffer;
-
-CSTDSTUBBUFFERRELEASE(&PSFactoryBuffer)
-
-extern const ExtendedProxyFileInfo dcom_ProxyFileInfo;
-extern const ExtendedProxyFileInfo ole32_objidl_ProxyFileInfo;
-extern const ExtendedProxyFileInfo ole32_oleidl_ProxyFileInfo;
-extern const ExtendedProxyFileInfo ole32_unknwn_ProxyFileInfo;
-
-static const ProxyFileInfo *OLE32_ProxyFileList[] = {
-  &dcom_ProxyFileInfo,
-  &ole32_objidl_ProxyFileInfo,
-  &ole32_oleidl_ProxyFileInfo,
-  &ole32_unknwn_ProxyFileInfo,
-  NULL
-};
-
 /***********************************************************************
  *           DllGetClassObject [OLE32.@]
  */
@@ -92,6 +74,5 @@ HRESULT WINAPI DllGetClassObject(REFCLSID rclsid, REFIID iid,LPVOID *ppv)
     if (IsEqualGUID(rclsid, &CLSID_StdComponentCategoriesMgr))
         return ComCatCF_Create(iid, ppv);
 
-    return NdrDllGetClassObject(rclsid, iid, ppv, OLE32_ProxyFileList,
-                                &CLSID_PSFactoryBuffer, &PSFactoryBuffer);
+    return OLE32_DllGetClassObject(rclsid, iid, ppv);
 }




More information about the wine-cvs mailing list