From: Álvaro Herrera Date: Fri, 31 Oct 2025 16:43:15 +0000 (+0100) Subject: pg_createsubscriber: Fix error complaining about the wrong thing X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=11144915e101eff94556192f5f18f6ac133da43e;p=thirdparty%2Fpostgresql.git pg_createsubscriber: Fix error complaining about the wrong thing The code updates the system identifier, then runs pg_walreset; if the latter fails, it complains about the former, which makes no sense. Change the error message to complain about the right thing. Noticed while reviewing a patch touching nearby code. Author: Álvaro Herrera Backpatch-through: 17 --- diff --git a/src/bin/pg_basebackup/pg_createsubscriber.c b/src/bin/pg_basebackup/pg_createsubscriber.c index 9fa5caaf91d..20d84512670 100644 --- a/src/bin/pg_basebackup/pg_createsubscriber.c +++ b/src/bin/pg_basebackup/pg_createsubscriber.c @@ -706,9 +706,9 @@ modify_subscriber_sysid(const struct CreateSubscriberOptions *opt) int rc = system(cmd_str); if (rc == 0) - pg_log_info("subscriber successfully changed the system identifier"); + pg_log_info("subscriber successfully reset WAL on the subscriber"); else - pg_fatal("could not change system identifier of subscriber: %s", wait_result_to_str(rc)); + pg_fatal("could not reset WAL on subscriber: %s", wait_result_to_str(rc)); } pg_free(cf);