pg.ddx.io  pgsql-hackers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Nathan Bossart <nathandbossart@gmail.com>
To: Sami Imseih <samimseih@gmail.com>
Cc: pgsql-hackers <pgsql-hackers@postgresql.org>
Subject: Re: GetNamedLWLockTranche crashes on Windows in normal backend
Date: Thu, 4 Sep 2025 13:41:01 -0500
Message-ID: <aLndPXAnzeCy7C3T@nathan> (raw)
In-Reply-To: <CAA5RZ0uCPdEngGPceCuqpOkeDR7uHA30M5hONhkJdcrmk+KLjQ@mail.gmail.com>
References: <aKyTa-iOdAfKynI1@nathan>
	<CAA5RZ0u4BDp4ENjOyZ7NADz+jdQY-=PZFQNsf0jBt1Va4QzoAA@mail.gmail.com>
	<aKyr_rVOtlolDcy-@nathan>
	<CAA5RZ0un+WRqsM35JUE97LOdrjGbE1VZpL0h0kaQn-_y5j8U0A@mail.gmail.com>
	<aKyzQuljgqo7-YIs@nathan>
	<CAA5RZ0tuKYaaS3ohjqXzxgk7xExz1VdP4Xyay9YxemJWr4vAfg@mail.gmail.com>
	<CAA5RZ0tUApqNpYbRq9dtWZZyWd8FhJxxjOLbU8yso=opJMuHtQ@mail.gmail.com>
	<aKzYgi0TbmcG-Y9l@nathan>
	<aLi075cWNyXQw-6G@nathan>
	<CAA5RZ0uCPdEngGPceCuqpOkeDR7uHA30M5hONhkJdcrmk+KLjQ@mail.gmail.com>

On Thu, Sep 04, 2025 at 01:23:26PM -0500, Sami Imseih wrote:
> I suggest we set an in progres flag for shmem_startup_hook, as we do for
> shmem_request_hook, and error out this function if called outside of this
> hook. The error will be something like this:
> 
> ```
> ERROR:  cannot return the address of LWLocks outside of shmem_startup_hook
> ```
> 
> We can also update the docs.
> 
> If you agree with the above, I'll get the patch ready?

Yeah, I think modeling this after commit 4f2400c is a reasonable thing to
explore.

-- 
nathan





view thread (33+ messages)  latest in thread

Message-ID: <aLndPXAnzeCy7C3T@nathan>
Permalink:  ../aLndPXAnzeCy7C3T@nathan/
Also on:    postgresql.org/message-id/aLndPXAnzeCy7C3T@nathan

 · 

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-hackers@postgresql.org
  Cc: nathandbossart@gmail.com, samimseih@gmail.com
  Subject: Re: GetNamedLWLockTranche crashes on Windows in normal backend
  In-Reply-To: <aLndPXAnzeCy7C3T@nathan>

* 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