pg.ddx.io  pgsql-bugs@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: PG Bug reporting form <noreply@postgresql.org>
To: pgsql-bugs@lists.postgresql.org
Cc: dan-eli@mail.ru
Subject: BUG #18891: /src/include/lib/simplehash.h possible palloc0 problems
Date: Thu, 10 Apr 2025 16:47:44 +0000
Message-ID: <18891-16499b7cbaf2661a@postgresql.org> (raw)

The following bug has been logged on the website:

Bug reference:      18891
Logged by:          Daniel Elishakov
Email address:      dan-eli@mail.ru
PostgreSQL version: 17.4
Operating system:   Ubuntu 20.04
Description:        

On line 1080 there is an initiallization of array with the usage of palloc0.
On the server side there is no problem as the server version of palloc never
returns NULL. However simplehash is used in some utils: pg_dump,
pg_verifybackup, pg_rewind. It seems these utils use the frontend version of
palloc. Therefore it is required to add a NULL check if FRONTEND macro is
defined.



view thread (2+ messages)  latest in thread

Message-ID: <18891-16499b7cbaf2661a@postgresql.org>
Permalink:  ../18891-16499b7cbaf2661a@postgresql.org/
Also on:    postgresql.org/message-id/18891-16499b7cbaf2661a@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-bugs@postgresql.org
  Cc: noreply@postgresql.org, pgsql-bugs@lists.postgresql.org, dan-eli@mail.ru
  Subject: Re: BUG #18891: /src/include/lib/simplehash.h possible palloc0 problems
  In-Reply-To: <18891-16499b7cbaf2661a@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