pgpool: Fix safer directory deletion in Bash in recovery_1st_stage.samp

From: Taiki Koshino <koshino(at)sraoss(dot)co(dot)jp>
To: pgpool-committers(at)lists(dot)postgresql(dot)org
Subject: pgpool: Fix safer directory deletion in Bash in recovery_1st_stage.samp
Date: 2025-09-10 06:28:52
Message-ID: E1uwEK4-000VyQ-0c@gothos.postgresql.org
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgpool-committers

Fix safer directory deletion in Bash in recovery_1st_stage.sample.

Quote variables in rm commands to avoid accidental deletion:
rm -rf "${DEST_NODE_PGDATA}"

If the variable is empty, rm could delete unexpected files or directories.

Branch
------
master

Details
-------
https://git.postgresql.org/gitweb?p=pgpool2.git;a=commitdiff;h=58446a66f8d7f461de0407f41a15e8fd9fe9035c

Modified Files
--------------
src/sample/scripts/recovery_1st_stage.sample | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

Browse pgpool-committers by date

  From Date Subject
Next Message Taiki Koshino 2025-09-17 07:42:49 pgpool: Update doc about "Setting up PostgreSQL standby" in "8.2. Pgpoo
Previous Message Taiki Koshino 2025-09-10 06:26:43 pgpool: Fix safer directory deletion in Bash in recovery_1st_stage.samp