pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: pgsql-committers@lists.postgresql.org
Subject: pgsql: Remove unnecessary complication around xmlParseBalancedChunkMemo
Date: Tue, 29 Jul 2025 16:47:58 +0000
Message-ID: <E1ugnUc-001LBE-1l@gemulon.postgresql.org> (raw)

Remove unnecessary complication around xmlParseBalancedChunkMemory.

When I prepared 71c0921b6 et al yesterday, I was thinking that the
logic involving explicitly freeing the node_list output was still
needed to dodge leakage bugs in libxml2.  But I was misremembering:
we introduced that only because with early 2.13.x releases we could
not trust xmlParseBalancedChunkMemory's result code, so we had to
look to see if a node list was returned or not.  There's no reason
to believe that xmlParseBalancedChunkMemory will fail to clean up
the node list when required, so simplify.  (This essentially
completes reverting all the non-cosmetic changes in 6082b3d5d.)

Reported-by: Jim Jones <jim.jones@uni-muenster.de>
Author: Tom Lane <tgl@sss.pgh.pa.us>
Discussion: https://postgr.es/m/997668.1753802857@sss.pgh.pa.us
Backpatch-through: 13

Branch
------
REL_18_STABLE

Details
-------
https://git.postgresql.org/pg/commitdiff/d5f014d897c81d1a610d8ee8084524aacf6ae3fb

Modified Files
--------------
src/backend/utils/adt/xml.c | 10 +---------
1 file changed, 1 insertion(+), 9 deletions(-)



view thread (7+ messages)  latest in thread

Message-ID: <E1ugnUc-001LBE-1l@gemulon.postgresql.org>
Permalink:  ../E1ugnUc-001LBE-1l@gemulon.postgresql.org/
Also on:    postgresql.org/message-id/E1ugnUc-001LBE-1l@gemulon.postgresql.org

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-committers@postgresql.org
  Cc: tgl@sss.pgh.pa.us, pgsql-committers@lists.postgresql.org
  Subject: Re: pgsql: Remove unnecessary complication around xmlParseBalancedChunkMemo
  In-Reply-To: <E1ugnUc-001LBE-1l@gemulon.postgresql.org>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox