aboutsummaryrefslogtreecommitdiffstats
path: root/parser.c
diff options
context:
space:
mode:
authorDaniel Veillard <veillard@redhat.com>2013-12-09 15:23:40 +0800
committerDaniel Veillard <veillard@redhat.com>2013-12-09 15:23:40 +0800
commit4e1476c5ea1a13397fe3c1001801cbceedfa0d3b (patch)
treef376e4851851916fba94fe99102832fdfe424b69 /parser.c
parent761c9e99019dfd778352f5d8ed037c5ca0272aa4 (diff)
downloadandroid_external_libxml2-4e1476c5ea1a13397fe3c1001801cbceedfa0d3b.tar.gz
android_external_libxml2-4e1476c5ea1a13397fe3c1001801cbceedfa0d3b.tar.bz2
android_external_libxml2-4e1476c5ea1a13397fe3c1001801cbceedfa0d3b.zip
adding init calls to xml and html Read parsing entry points
As pointed out by "Tassyns, Bram <BramT@enfocus.com>" on the list some call had it other didn't, clean it up and add to all missing ones
Diffstat (limited to 'parser.c')
-rw-r--r--parser.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/parser.c b/parser.c
index d9844be5..87d4794e 100644
--- a/parser.c
+++ b/parser.c
@@ -15221,6 +15221,7 @@ xmlReadDoc(const xmlChar * cur, const char *URL, const char *encoding, int optio
if (cur == NULL)
return (NULL);
+ xmlInitParser();
ctxt = xmlCreateDocParserCtxt(cur);
if (ctxt == NULL)
@@ -15243,6 +15244,7 @@ xmlReadFile(const char *filename, const char *encoding, int options)
{
xmlParserCtxtPtr ctxt;
+ xmlInitParser();
ctxt = xmlCreateURLParserCtxt(filename, options);
if (ctxt == NULL)
return (NULL);
@@ -15266,6 +15268,7 @@ xmlReadMemory(const char *buffer, int size, const char *URL, const char *encodin
{
xmlParserCtxtPtr ctxt;
+ xmlInitParser();
ctxt = xmlCreateMemoryParserCtxt(buffer, size);
if (ctxt == NULL)
return (NULL);
@@ -15294,6 +15297,7 @@ xmlReadFd(int fd, const char *URL, const char *encoding, int options)
if (fd < 0)
return (NULL);
+ xmlInitParser();
input = xmlParserInputBufferCreateFd(fd, XML_CHAR_ENCODING_NONE);
if (input == NULL)
@@ -15337,6 +15341,7 @@ xmlReadIO(xmlInputReadCallback ioread, xmlInputCloseCallback ioclose,
if (ioread == NULL)
return (NULL);
+ xmlInitParser();
input = xmlParserInputBufferCreateIO(ioread, ioclose, ioctx,
XML_CHAR_ENCODING_NONE);
@@ -15383,6 +15388,7 @@ xmlCtxtReadDoc(xmlParserCtxtPtr ctxt, const xmlChar * cur,
return (NULL);
if (ctxt == NULL)
return (NULL);
+ xmlInitParser();
xmlCtxtReset(ctxt);
@@ -15416,6 +15422,7 @@ xmlCtxtReadFile(xmlParserCtxtPtr ctxt, const char *filename,
return (NULL);
if (ctxt == NULL)
return (NULL);
+ xmlInitParser();
xmlCtxtReset(ctxt);
@@ -15452,6 +15459,7 @@ xmlCtxtReadMemory(xmlParserCtxtPtr ctxt, const char *buffer, int size,
return (NULL);
if (buffer == NULL)
return (NULL);
+ xmlInitParser();
xmlCtxtReset(ctxt);
@@ -15496,6 +15504,7 @@ xmlCtxtReadFd(xmlParserCtxtPtr ctxt, int fd,
return (NULL);
if (ctxt == NULL)
return (NULL);
+ xmlInitParser();
xmlCtxtReset(ctxt);
@@ -15541,6 +15550,7 @@ xmlCtxtReadIO(xmlParserCtxtPtr ctxt, xmlInputReadCallback ioread,
return (NULL);
if (ctxt == NULL)
return (NULL);
+ xmlInitParser();
xmlCtxtReset(ctxt);