Fix AtlAxWinInit()

Francois Gouget fgouget at free.fr
Fri Dec 2 05:25:09 CST 2005


Why don't we put atliface.idl in include/atl? This is where altiface.h 
is found in the Windows SDK (except in the 20051117 preview which does 
not have this directory at all).

All the AtlAxWinInit() documentation say that it returns TRUE if 
successful and FALSE otherwise which is consistent with its prototype. 
However some of the MSDN entries have a second 'Return Value' section 
saying it returns one of the standard HRESULT values. However I think 
that section 'Return Value' section is a copy/paste error and makes no 
sense given the function's return type.


Changelog:

  * dlls/atl/atliface.idl
    dlls/atl/atl_main.c

    Francois Gouget <fgouget at free.fr>
    Fix the AtlAxWinInit() prototype.
    Also make it return FALSE to indicate failure instead of E_FAIL.
    Define AtlAxWinInit() and AtlAxCreateControl() in atliface.idl.

-- 
Francois Gouget         fgouget at free.fr        http://fgouget.free.fr/
In theory, theory and practice are the same, but in practice they're different.
-------------- next part --------------
Index: dlls/atl/atliface.idl
===================================================================
RCS file: /var/cvs/wine/dlls/atl/atliface.idl,v
retrieving revision 1.1
diff -u -p -r1.1 atliface.idl
--- dlls/atl/atliface.idl	14 Mar 2005 10:51:27 -0000	1.1
+++ dlls/atl/atliface.idl	29 Nov 2005 11:40:57 -0000
@@ -69,3 +69,6 @@ interface IRegistrar : IUnknown
 }
 
 cpp_quote("DEFINE_GUID(CLSID_ATLRegistrar,0x44ec053a,0x400f,0x11d0,0x9d,0xcd,0x00,0xa0,0xc9,0x03,0x91,0xd3);")
+
+cpp_quote("HRESULT WINAPI AtlAxCreateControl(LPCOLESTR,HWND,IStream*,IUnknown**);")
+cpp_quote("BOOL WINAPI AtlAxWinInit(void);")
Index: dlls/atl/atl_main.c
===================================================================
RCS file: /var/cvs/wine/dlls/atl/atl_main.c,v
retrieving revision 1.17
diff -u -p -r1.17 atl_main.c
--- dlls/atl/atl_main.c	28 Nov 2005 11:05:37 -0000	1.17
+++ dlls/atl/atl_main.c	29 Nov 2005 11:41:46 -0000
@@ -174,10 +174,10 @@ HRESULT WINAPI AtlModuleUnregisterServer
  *  TRUE or FALSE
  */
 
-HRESULT WINAPI AtlAxWinInit(void)
+BOOL WINAPI AtlAxWinInit(void)
 {
     FIXME("Try use native atl.dll if possible\n");
-    return E_FAIL;
+    return FALSE;
 }
 
 


More information about the wine-patches mailing list