|
|
267d54 |
From 5b3397ee81277ed70af58a247a0d731de9c7a6c7 Mon Sep 17 00:00:00 2001
|
|
|
267d54 |
From: Daniel Veillard <veillard@redhat.com>
|
|
|
267d54 |
Date: Mon, 9 Nov 2015 18:16:00 +0800
|
|
|
267d54 |
Subject: [PATCH] xmlStopParser reset errNo
|
|
|
267d54 |
To: libvir-list@redhat.com
|
|
|
267d54 |
|
|
|
267d54 |
I had used it in contexts where that information ought to be preserved
|
|
|
267d54 |
|
|
|
267d54 |
Signed-off-by: Daniel Veillard <veillard@redhat.com>
|
|
|
267d54 |
---
|
|
|
267d54 |
parser.c | 3 +++
|
|
|
267d54 |
1 file changed, 3 insertions(+)
|
|
|
267d54 |
|
|
|
267d54 |
diff --git a/parser.c b/parser.c
|
|
|
267d54 |
index 134ea7f..a58dda3 100644
|
|
|
267d54 |
--- a/parser.c
|
|
|
267d54 |
+++ b/parser.c
|
|
|
267d54 |
@@ -6762,6 +6762,7 @@ xmlParseConditionalSections(xmlParserCtxtPtr ctxt) {
|
|
|
267d54 |
if (RAW != '[') {
|
|
|
267d54 |
xmlFatalErr(ctxt, XML_ERR_CONDSEC_INVALID, NULL);
|
|
|
267d54 |
xmlStopParser(ctxt);
|
|
|
267d54 |
+ ctxt->errNo = XML_ERR_CONDSEC_INVALID;
|
|
|
267d54 |
return;
|
|
|
267d54 |
} else {
|
|
|
267d54 |
if (ctxt->input->id != id) {
|
|
|
267d54 |
@@ -6824,6 +6825,7 @@ xmlParseConditionalSections(xmlParserCtxtPtr ctxt) {
|
|
|
267d54 |
if (RAW != '[') {
|
|
|
267d54 |
xmlFatalErr(ctxt, XML_ERR_CONDSEC_INVALID, NULL);
|
|
|
267d54 |
xmlStopParser(ctxt);
|
|
|
267d54 |
+ ctxt->errNo = XML_ERR_CONDSEC_INVALID;
|
|
|
267d54 |
return;
|
|
|
267d54 |
} else {
|
|
|
267d54 |
if (ctxt->input->id != id) {
|
|
|
267d54 |
@@ -6881,6 +6883,7 @@ xmlParseConditionalSections(xmlParserCtxtPtr ctxt) {
|
|
|
267d54 |
} else {
|
|
|
267d54 |
xmlFatalErr(ctxt, XML_ERR_CONDSEC_INVALID_KEYWORD, NULL);
|
|
|
267d54 |
xmlStopParser(ctxt);
|
|
|
267d54 |
+ ctxt->errNo = XML_ERR_CONDSEC_INVALID_KEYWORD;
|
|
|
267d54 |
return;
|
|
|
267d54 |
}
|
|
|
267d54 |
|
|
|
267d54 |
--
|
|
|
267d54 |
2.5.0
|
|
|
267d54 |
|