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: Fix datatype confusion in logtape.c's right_offset().
Date: Tue, 14 Dec 2021 16:47:03 +0000
Message-ID: <E1mxAxD-0005SR-Sj@gemulon.postgresql.org> (raw)

Fix datatype confusion in logtape.c's right_offset().

This could only matter if (a) long is wider than int, and (b) the heap
of free blocks exceeds UINT_MAX entries, which seems pretty unlikely.
Still, it's a theoretical bug, so backpatch to v13 where the typo came
in (in commit c02fdc922).

In passing, also make swap_nodes() use consistent datatypes.

Ma Liangzhu

Discussion: https://postgr.es/m/17336-fc4e522d26a750fd@postgresql.org

Branch
------
REL_13_STABLE

Details
-------
https://git.postgresql.org/pg/commitdiff/0a5682041dbf991bd325a7d14daf39ecfc9bd624

Modified Files
--------------
src/backend/utils/sort/logtape.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)



view thread (3+ messages)  latest in thread

Message-ID: <E1mxAxD-0005SR-Sj@gemulon.postgresql.org>
Permalink:  ../E1mxAxD-0005SR-Sj@gemulon.postgresql.org/
Also on:    postgresql.org/message-id/E1mxAxD-0005SR-Sj@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 from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-committers@postgresql.org
  Cc: tgl@sss.pgh.pa.us
  Subject: Re: pgsql: Fix datatype confusion in logtape.c's right_offset().
  In-Reply-To: <E1mxAxD-0005SR-Sj@gemulon.postgresql.org>
  References: <E1mxAxD-0005SR-Sj@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