pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Fujii Masao <fujii@postgresql.org>
To: pgsql-committers@lists.postgresql.org
Subject: pgsql: Deduplicate code in LargeObjectExists and myLargeObjectExists.
Date: Thu, 12 Sep 2024 12:55:37 +0000
Message-ID: <E1sojMH-000kKi-LS@gemulon.postgresql.org> (raw)

Deduplicate code in LargeObjectExists and myLargeObjectExists.

myLargeObjectExists() and LargeObjectExists() had nearly identical code,
except for handling snapshots. This commit renames myLargeObjectExists()
to LargeObjectExistsWithSnapshot() and refactors LargeObjectExists()
to call it internally, reducing duplication.

Author: Yugo Nagata
Reviewed-by: Fujii Masao
Discussion: https://postgr.es/m/20240702163444.ab586f6075e502eb84f11b1a@sranhm.sraoss.co.jp

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/412229d197f894a01c163b9e9fdfec1a1855f7ab

Modified Files
--------------
src/backend/catalog/pg_largeobject.c       | 13 +++++++---
src/backend/storage/large_object/inv_api.c | 40 +-----------------------------
src/include/catalog/pg_largeobject.h       |  2 ++
3 files changed, 13 insertions(+), 42 deletions(-)



Message-ID: <E1sojMH-000kKi-LS@gemulon.postgresql.org>
Permalink:  ../E1sojMH-000kKi-LS@gemulon.postgresql.org/
Also on:    postgresql.org/message-id/E1sojMH-000kKi-LS@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: fujii@postgresql.org, pgsql-committers@lists.postgresql.org
  Subject: Re: pgsql: Deduplicate code in LargeObjectExists and myLargeObjectExists.
  In-Reply-To: <E1sojMH-000kKi-LS@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