Re: Usage of ProcessConfigfile in SIGHUP_Handler

From: Nathan Bossart <nathandbossart(at)gmail(dot)com>
To: Lakshmi Narayana Velayudam <dev(dot)narayana(dot)v(at)gmail(dot)com>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: Usage of ProcessConfigfile in SIGHUP_Handler
Date: 2024-08-22 15:16:00
Message-ID: ZsdWMMsy_qBzyecI@nathan
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Thu, Aug 22, 2024 at 05:37:13PM +0530, Lakshmi Narayana Velayudam wrote:
> Later I have seen almost
> all postgresql processes/bgworkers use signal handler to set a
> variable *ConfigReloadPending
> *which will later be read in main code to process guc changes but for
> postmaster *ProcessConfigfile *is being called from signal handler itself
> which intern has memory allocation related code (non-async safe code). Is
> it safe to do this?

I think this is no longer true as of v16, thanks to commit 7389aad [0].

[0] https://git.postgresql.org/gitweb/?p=postgresql.git;a=commit;h=7389aad

--
nathan

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Nathan Bossart 2024-08-22 15:29:00 Re: Proposal for Updating CRC32C with AVX-512 Algorithm.
Previous Message Amonson, Paul D 2024-08-22 15:14:32 RE: Proposal for Updating CRC32C with AVX-512 Algorithm.