[xml] xmlParseMemory Problem !!

Hi All,

I am trying to parse an xml string using  xmlParseMemory function and
I have downloaed libxml2.4.4. I am using gcc 2.98.81 compiler on RedHat 7.1.

my lib settings are as follows:

LIBXML_LIB=/usr/lib/libxml2.so.2.4.4 /usr/lib/libxml2.a  /usr/lib/libxml2.so.2.4.1

I am getting follwoing error:

#0  0x401c400a in chunk_free (ar_ptr=0x4026cf00, p=0x99a49ba3) at malloc.c:3125
#1  0x401c3716 in chunk_alloc (ar_ptr=0x4026cf00, nb=4008) at malloc.c:2612
#2  0x401c313a in __libc_malloc (bytes=4000) at malloc.c:2714
#3  0x40085055 in xmlBufferCreate () from /usr/lib/libxml2.so.2
#4  0x400898a3 in xmlAllocParserInputBuffer () from /usr/lib/libxml2.so.2
#5  0x4008a0b2 in xmlParserInputBufferCreateMem () from /usr/lib/libxml2.so.2
#6  0x4007fbac in xmlCreateMemoryParserCtxt () from /usr/lib/libxml2.so.2
#7  0x4007fc31 in xmlSAXParseMemory () from /usr/lib/libxml2.so.2
#8  0x4007fcd3 in xmlParseMemory () from /usr/lib/libxml2.so.2

I tried to look for these in archive also but could not find any related thread.  I have very less time please help and let me know whether I am using correct version or not ??

my xml string is :

<?xml version="1.0" encoding="UTF-8"?>
<epp xmlns="urn:iana:xml:ns:epp-1.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="urn:iana:xml:ns:epp-1.0 epp-1.0.xsd">
  <result code="1000">
   <msg lang="en-US">Command Completed successfully</msg>

and code is

char * msg;
rootNode = xmlParseMemory(msg,strlen(msg));

where msg is string shoen above.

Please help me.


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]