mirror of
git://source.winehq.org/git/wine.git
synced 2024-09-01 10:53:38 +00:00
msxml3: Do not depend on libxml2 for msxwriter object.
Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com> Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
parent
99d2bda555
commit
5a39fab458
|
@ -113,4 +113,35 @@ void release_dispex(DispatchEx*) DECLSPEC_HIDDEN;
|
|||
BOOL dispex_query_interface(DispatchEx*,REFIID,void**) DECLSPEC_HIDDEN;
|
||||
const IID *get_riid_from_tid(enum tid_t tid) DECLSPEC_HIDDEN;
|
||||
|
||||
static inline HRESULT return_bstr(const WCHAR *value, BSTR *p)
|
||||
{
|
||||
if (!p)
|
||||
return E_INVALIDARG;
|
||||
|
||||
if (value)
|
||||
{
|
||||
*p = SysAllocString(value);
|
||||
if (!*p)
|
||||
return E_OUTOFMEMORY;
|
||||
}
|
||||
else
|
||||
*p = NULL;
|
||||
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
static inline HRESULT return_bstrn(const WCHAR *value, int len, BSTR *p)
|
||||
{
|
||||
if (value)
|
||||
{
|
||||
*p = SysAllocStringLen(value, len);
|
||||
if (!*p)
|
||||
return E_OUTOFMEMORY;
|
||||
}
|
||||
else
|
||||
*p = NULL;
|
||||
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
#endif /* __MSXML_DISPEX__ */
|
||||
|
|
|
@ -340,34 +340,6 @@ static inline xmlChar *heap_strdupxmlChar(const xmlChar *str)
|
|||
|
||||
#endif
|
||||
|
||||
static inline HRESULT return_bstr(const WCHAR *value, BSTR *p)
|
||||
{
|
||||
if(!p)
|
||||
return E_INVALIDARG;
|
||||
|
||||
if(value) {
|
||||
*p = SysAllocString(value);
|
||||
if(!*p)
|
||||
return E_OUTOFMEMORY;
|
||||
}else {
|
||||
*p = NULL;
|
||||
}
|
||||
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
static inline HRESULT return_bstrn(const WCHAR *value, int len, BSTR *p)
|
||||
{
|
||||
if(value) {
|
||||
*p = SysAllocStringLen(value, len);
|
||||
if(!*p)
|
||||
return E_OUTOFMEMORY;
|
||||
}else
|
||||
*p = NULL;
|
||||
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
static inline HRESULT return_null_node(IXMLDOMNode **p)
|
||||
{
|
||||
if(!p)
|
||||
|
|
|
@ -20,12 +20,8 @@
|
|||
*/
|
||||
|
||||
#define COBJMACROS
|
||||
#include "config.h"
|
||||
|
||||
#include <stdarg.h>
|
||||
#ifdef HAVE_LIBXML2
|
||||
# include <libxml/parser.h>
|
||||
#endif
|
||||
|
||||
#include "windef.h"
|
||||
#include "winbase.h"
|
||||
|
@ -34,9 +30,9 @@
|
|||
#include "msxml6.h"
|
||||
|
||||
#include "wine/debug.h"
|
||||
#include "wine/list.h"
|
||||
#include "wine/unicode.h"
|
||||
|
||||
#include "msxml_private.h"
|
||||
#include "msxml_dispex.h"
|
||||
|
||||
WINE_DEFAULT_DEBUG_CHANNEL(msxml);
|
||||
|
||||
|
@ -258,7 +254,7 @@ static xml_encoding parse_encoding_name(const WCHAR *encoding)
|
|||
{
|
||||
n = (min+max)/2;
|
||||
|
||||
c = strcmpiW(xml_encoding_map[n].encoding, encoding);
|
||||
c = lstrcmpiW(xml_encoding_map[n].encoding, encoding);
|
||||
if (!c)
|
||||
return xml_encoding_map[n].enc;
|
||||
|
||||
|
@ -347,7 +343,7 @@ static HRESULT write_output_buffer(mxwriter *writer, const WCHAR *data, int len)
|
|||
if (!len || !*data)
|
||||
return S_OK;
|
||||
|
||||
src_len = len == -1 ? strlenW(data) : len;
|
||||
src_len = len == -1 ? lstrlenW(data) : len;
|
||||
if (writer->dest)
|
||||
{
|
||||
buff = &buffer->encoded;
|
||||
|
|
Loading…
Reference in a new issue