pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Masahiko Sawada <msawada@postgresql.org>
To: pgsql-committers@lists.postgresql.org
Subject: pgsql: radixtree: Fix crash when non-creator begins iteration over shar
Date: Thu, 06 Feb 2025 19:37:09 +0000
Message-ID: <E1tg7gT-005ipX-Jo@gemulon.postgresql.org> (raw)

radixtree: Fix crash when non-creator begins iteration over shared tree.

Previously, if a backend that attached to a shared tree attempted to
start iteration, it resulted in a crash. This commit resolves the
issue by ensuring iter_context is created in RT_ATTACH().

This fix applies only to v17, where radixtree.h was introduced. In the
master branch, this issue was separately resolved by 960013f2a1, which
eliminated the iter_context entirely.

Reviewed-by: John Naylor
Discussion: https://postgr.es/m/CAD21AoBB2U47V=F+wQRB1bERov_of5=BOZGaybjaV8FLQyqG3Q@mail.gmail.com

Branch
------
REL_17_STABLE

Details
-------
https://git.postgresql.org/pg/commitdiff/9af2b3435844526ff503f2509c5246749b9c48b0

Modified Files
--------------
src/include/lib/radixtree.h | 10 ++++++++++
1 file changed, 10 insertions(+)



Message-ID: <E1tg7gT-005ipX-Jo@gemulon.postgresql.org>
Permalink:  ../E1tg7gT-005ipX-Jo@gemulon.postgresql.org/
Also on:    postgresql.org/message-id/E1tg7gT-005ipX-Jo@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: msawada@postgresql.org, pgsql-committers@lists.postgresql.org
  Subject: Re: pgsql: radixtree: Fix crash when non-creator begins iteration over shar
  In-Reply-To: <E1tg7gT-005ipX-Jo@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