pg_resetwal: Fix incorrect error message related to pg_wal/summaries/

A failure while closing pg_wal/summaries/ incorrectly generated a report
about pg_wal/archive_status/.

While at it, this commit adds #undefs for the macros used in
KillExistingWALSummaries() and KillExistingArchiveStatus() to prevent
those values from being misused in an incorrect function context.

Oversight in dc212340058b.

Author: Tianchen Zhang <[email protected]>
Reviewed-by: Chao Li <[email protected]>
Reviewed-by: Kyotaro Horiguchi <[email protected]>
Discussion: 
https://postgr.es/m/se2p216mb2390c84c23f428a7864ee07fa1...@se2p216mb2390.korp216.prod.outlook.com
Backpatch-through: 17

Branch
------
REL_18_STABLE

Details
-------
https://git.postgresql.org/pg/commitdiff/2ca4464b6992508a6be201ff8f10847e64e2291d

Modified Files
--------------
src/bin/pg_resetwal/pg_resetwal.c | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)

Reply via email to