From d83ff954af4693fca75834fc56f27f635ce20e75 Mon Sep 17 00:00:00 2001 From: Nick Wellnhofer Date: Tue, 11 Mar 2025 11:23:34 +0100 Subject: [PATCH] xmllint: Make sure that parser options are used --- xmllint.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/xmllint.c b/xmllint.c index 797098e3a..9c7d4cd6f 100644 --- a/xmllint.c +++ b/xmllint.c @@ -3501,12 +3501,12 @@ xmllintMain(int argc, const char **argv, FILE *errStream, ctxt = htmlCreatePushParserCtxt(NULL, NULL, NULL, 0, filename, XML_CHAR_ENCODING_NONE); - htmlCtxtUseOptions(ctxt, lint->options); } else #endif /* LIBXML_PUSH_ENABLED */ { ctxt = htmlNewParserCtxt(); } + htmlCtxtUseOptions(ctxt, lint->options); } else #endif /* LIBXML_HTML_ENABLED */ { @@ -3514,12 +3514,12 @@ xmllintMain(int argc, const char **argv, FILE *errStream, if (lint->push) { ctxt = xmlCreatePushParserCtxt(NULL, NULL, NULL, 0, filename); - xmlCtxtUseOptions(ctxt, lint->options); } else #endif /* LIBXML_PUSH_ENABLED */ { ctxt = xmlNewParserCtxt(); } + xmlCtxtUseOptions(ctxt, lint->options); } if (ctxt == NULL) { lint->progresult = XMLLINT_ERR_MEM;