Projects
openEuler:24.03:SP1:Everything
expat
_service:tar_scm:backport-002-CVE-2023-52425.patch
Sign Up
Log In
Username
Password
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File _service:tar_scm:backport-002-CVE-2023-52425.patch of Package expat
From c3a4816e175ede7da1a692a50d6251efdfe41a45 Mon Sep 17 00:00:00 2001 From: Snild Dolkow <snild@sony.com> Date: Mon, 4 Sep 2023 17:21:14 +0200 Subject: [PATCH] Don't update partial token heuristic on error Reference: https://github.com/libexpat/libexpat/pull/789/commits/1b9d398517befeb944cbbadadf10992b07e96fa2 Conflict: no Suggested-by: Sebastian Pipping <sebastian@pipping.org> --- lib/xmlparse.c | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/lib/xmlparse.c b/lib/xmlparse.c index 32df1eb9..a8414dd7 100644 --- a/lib/xmlparse.c +++ b/lib/xmlparse.c @@ -963,11 +963,13 @@ callProcessor(XML_Parser parser, const char *start, const char *end, } } const enum XML_Error ret = parser->m_processor(parser, start, end, endPtr); - // if we consumed nothing, remember what we had on this parse attempt. - if (*endPtr == start) { - parser->m_partialTokenBytesBefore = have_now; - } else { - parser->m_partialTokenBytesBefore = 0; + if (ret == XML_ERROR_NONE) { + // if we consumed nothing, remember what we had on this parse attempt. + if (*endPtr == start) { + parser->m_partialTokenBytesBefore = have_now; + } else { + parser->m_partialTokenBytesBefore = 0; + } } return ret; } -- 2.33.0
Locations
Projects
Search
Status Monitor
Help
Open Build Service
OBS Manuals
API Documentation
OBS Portal
Reporting a Bug
Contact
Mailing List
Forums
Chat (IRC)
Twitter
Open Build Service (OBS)
is an
openSUSE project
.
浙ICP备2022010568号-2