public inbox for [email protected]  
help / color / mirror / Atom feed
From: Ayush Tiwari <[email protected]>
To: [email protected]
Subject: [PATCH] postmaster: fix stale PM_STARTUP comment
Date: Wed, 15 Apr 2026 19:27:16 +0530
Message-ID: <CAJTYsWVoD3V9yhhqSae1_wqcnTdpFY-hDT7dPm5005ZFsL_bpA@mail.gmail.com> (raw)

Hi,

The comment above the PM_STARTUP startup-process-failure case still says
that there are no other processes running yet, so the postmaster can just
exit.

That no longer matches the current startup flow: PM_STARTUP may already
have auxiliary processes running by that point. The attached patch updates
that comment to describe the current behavior.

Regards,
Ayush


Attachments:

  [application/octet-stream] 0001-postmaster-fix-stale-pm_startup-comment.patch (1.3K, 3-0001-postmaster-fix-stale-pm_startup-comment.patch)
  download | inline diff:
From 972c14fb9134fdfd76ea6ebcf98a55a945bbc988 Mon Sep 17 00:00:00 2001
From: Ayush Tiwari <[email protected]>
Date: Wed, 15 Apr 2026 18:54:56 +0530
Subject: [PATCH] postmaster: fix stale PM_STARTUP comment

The comment above the PM_STARTUP startup-process-failure case still says
there are no other processes running yet.

That is no longer accurate: other postmaster children may already be
running by this point. Adjust the comment to describe the current
behavior more accurately.

---
 src/backend/postmaster/postmaster.c | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/src/backend/postmaster/postmaster.c b/src/backend/postmaster/postmaster.c
index 6e0f41d2661e..d0b2e0bc8d2e 100644
--- a/src/backend/postmaster/postmaster.c
+++ b/src/backend/postmaster/postmaster.c
@@ -2307,8 +2307,9 @@ process_pm_child_exit(void)
			/*
			 * Unexpected exit of startup process (including FATAL exit)
-			 * during PM_STARTUP is treated as catastrophic. There are no
-			 * other processes running yet, so we can just exit.
+			 * during PM_STARTUP is treated as catastrophic. While other
+			 * postmaster children may already be running, this leaves the
+			 * system in an unrecoverable state requiring immediate exit.
			 */
			if (pmState == PM_STARTUP &&
				StartupStatus != STARTUP_SIGNALED &&
-- 
2.34.1


view thread (8+ messages)  latest in thread

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: [email protected]
  Cc: [email protected]
  Subject: Re: [PATCH] postmaster: fix stale PM_STARTUP comment
  In-Reply-To: <CAJTYsWVoD3V9yhhqSae1_wqcnTdpFY-hDT7dPm5005ZFsL_bpA@mail.gmail.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox