Commit 477fd6ef authored by Nikolay Sivov's avatar Nikolay Sivov Committed by Alexandre Julliard

msxml3: libxml2 is not used for writer.

parent 02414775
......@@ -375,6 +375,27 @@ static inline BSTR bstr_from_xmlChar(const xmlChar *str)
return ret;
}
static inline xmlChar *xmlchar_from_wcharn(const WCHAR *str, int nchars)
{
xmlChar *xmlstr;
DWORD len = WideCharToMultiByte( CP_UTF8, 0, str, nchars, NULL, 0, NULL, NULL );
xmlstr = heap_alloc( len+1 );
if ( xmlstr )
{
WideCharToMultiByte( CP_UTF8, 0, str, nchars, (LPSTR) xmlstr, len+1, NULL, NULL );
xmlstr[len] = 0;
}
return xmlstr;
}
static inline xmlChar *xmlchar_from_wchar( const WCHAR *str )
{
return xmlchar_from_wcharn(str, -1);
}
#endif
static inline HRESULT return_bstr(const WCHAR *value, BSTR *p)
{
if(!p)
......@@ -425,27 +446,6 @@ static inline HRESULT return_null_bstr(BSTR *p)
return S_FALSE;
}
static inline xmlChar *xmlchar_from_wcharn(const WCHAR *str, int nchars)
{
xmlChar *xmlstr;
DWORD len = WideCharToMultiByte( CP_UTF8, 0, str, nchars, NULL, 0, NULL, NULL );
xmlstr = heap_alloc( len+1 );
if ( xmlstr )
{
WideCharToMultiByte( CP_UTF8, 0, str, nchars, (LPSTR) xmlstr, len+1, NULL, NULL );
xmlstr[len] = 0;
}
return xmlstr;
}
static inline xmlChar *xmlchar_from_wchar( const WCHAR *str )
{
return xmlchar_from_wcharn(str, -1);
}
#endif
extern IXMLDOMParseError *create_parseError( LONG code, BSTR url, BSTR reason, BSTR srcText,
LONG line, LONG linepos, LONG filepos ) DECLSPEC_HIDDEN;
extern HRESULT DOMDocument_create(MSXML_VERSION, IUnknown*, void**) DECLSPEC_HIDDEN;
......
......@@ -39,8 +39,6 @@
WINE_DEFAULT_DEBUG_CHANNEL(msxml);
#ifdef HAVE_LIBXML2
static const WCHAR utf16W[] = {'U','T','F','-','1','6',0};
static const WCHAR emptyW[] = {0};
......@@ -1144,14 +1142,3 @@ HRESULT MXWriter_create(MSXML_VERSION version, IUnknown *outer, void **ppObj)
return S_OK;
}
#else
HRESULT MXWriter_create(MSXML_VERSION version, IUnknown *outer, void **obj)
{
MESSAGE("This program tried to use a MXXMLWriter object, but\n"
"libxml2 support was not present at compile time.\n");
return E_NOTIMPL;
}
#endif /* HAVE_LIBXML2 */
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment