msxml3: Fix compilation on systems that don't have xsltInit().
Francois Gouget
fgouget at codeweavers.com
Wed Nov 19 01:40:25 CST 2008
Reduce the scope of xsltInit().
Remove an include that was needed only for xsltInit().
---
Of course the versions of libxslt that don't have xsltInit() don't
define it in their headers either. So we cannot use typeof() for it.
Duh!
Spotted by Lei Zhang.
dlls/msxml3/main.c | 3 ++-
dlls/msxml3/msxml_private.h | 2 --
2 files changed, 2 insertions(+), 3 deletions(-)
diff --git a/dlls/msxml3/main.c b/dlls/msxml3/main.c
index 3084625..358a5cb 100644
--- a/dlls/msxml3/main.c
+++ b/dlls/msxml3/main.c
@@ -49,7 +49,6 @@ HRESULT WINAPI DllCanUnloadNow(void)
void* libxslt_handle = NULL;
#ifdef SONAME_LIBXSLT
# define DECL_FUNCPTR(f) typeof(f) * p##f = NULL
-DECL_FUNCPTR(xsltInit);
DECL_FUNCPTR(xsltApplyStylesheet);
DECL_FUNCPTR(xsltCleanupGlobals);
DECL_FUNCPTR(xsltFreeStylesheet);
@@ -60,6 +59,8 @@ DECL_FUNCPTR(xsltParseStylesheetDoc);
static void init_libxslt(void)
{
#ifdef SONAME_LIBXSLT
+ void (*pxsltInit)(void); /* Missing in libxslt <= 1.1.14 */
+
libxslt_handle = wine_dlopen(SONAME_LIBXSLT, RTLD_NOW, NULL, 0);
if (!libxslt_handle)
return;
diff --git a/dlls/msxml3/msxml_private.h b/dlls/msxml3/msxml_private.h
index 56a5b39..aa14b9b 100644
--- a/dlls/msxml3/msxml_private.h
+++ b/dlls/msxml3/msxml_private.h
@@ -102,10 +102,8 @@ void* libxslt_handle;
# endif
# include <libxslt/xsltutils.h>
# include <libxslt/xsltInternals.h>
-# include <libxslt/xslt.h>
# define MAKE_FUNCPTR(f) extern typeof(f) * p##f
-MAKE_FUNCPTR(xsltInit);
MAKE_FUNCPTR(xsltApplyStylesheet);
MAKE_FUNCPTR(xsltCleanupGlobals);
MAKE_FUNCPTR(xsltFreeStylesheet);
--
1.5.6.5
More information about the wine-patches
mailing list