From 74dfc49b5fa53c5b1ac8e920e494fbc81e857231 Mon Sep 17 00:00:00 2001 From: Nick Wellnhofer Date: Thu, 26 Sep 2024 21:24:00 +0200 Subject: [PATCH] parser: Clarify logic in xmlParseStartTag2 --- parser.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/parser.c b/parser.c index 8bb5fee1..945e80b0 100644 --- a/parser.c +++ b/parser.c @@ -9389,11 +9389,11 @@ next_attr: nsIndex = NS_INDEX_EMPTY; nsuri = NULL; uriHashValue = URI_HASH_EMPTY; - } if (aprefix == ctxt->str_xml) { + } else if (aprefix == ctxt->str_xml) { nsIndex = NS_INDEX_XML; nsuri = ctxt->str_xml_ns; uriHashValue = URI_HASH_XML; - } else if (aprefix != NULL) { + } else { nsIndex = xmlParserNsLookup(ctxt, &attr->prefix, NULL); if ((nsIndex == INT_MAX) || (nsIndex < ctxt->nsdb->minNsIndex)) {