[xml] Proceed on error.
- From: "Morten W. J." <morten newtec dk>
- To: xml gnome org
- Subject: [xml] Proceed on error.
- Date: Fri, 14 Jan 2005 11:19:50 +0100
Hello all.
I use libxml (2.6.7) to check if a string of XML is well formed by running it
through xmlParseMemory.
Sometimes, eg. when encountering "<nacho" or "<d></d><e>", libxml prints an
error similar to
"Entity: line 1: error: Couldn't find end of Start Tag nacho"
or
"Entity: line 1: error: Extra content at the end of the document" and halts
execution.
I just want to catch if the returned doc is NULL or not, free it and return a
proper value from my function.
Any idea on how I get xmlParseMemory to proceed instead of halting or any
alternative ideas?
--
Morten W. Jørgensen
Newtec A/S
StærmosegÂrdsvej 18
5230 Odense M
Denmark
Tlf.: 66 15 84 44
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]