aboutsummaryrefslogtreecommitdiff
path: root/src/backend/utils/adt/numeric.c
diff options
context:
space:
mode:
authorMichael Paquier <michael@paquier.xyz>2022-03-01 12:52:25 +0900
committerMichael Paquier <michael@paquier.xyz>2022-03-01 12:52:25 +0900
commita33e17f210547226ada52d2b8af851c3553bb4fa (patch)
treea01e715e2076aa06e8b3abd34252644739e1f4f4 /src/backend/utils/adt/numeric.c
parent7a85073290856554416353a89799a4c04d09b74b (diff)
downloadpostgresql-a33e17f210547226ada52d2b8af851c3553bb4fa.tar.gz
postgresql-a33e17f210547226ada52d2b8af851c3553bb4fa.zip
Rework internal command generation of pg_rewind
pg_rewind generates and executes internally up to two commands to work on the target cluster, depending on the options given by its caller: - postgres -C to retrieve the value of restore_command, when using -c/--restore-target-wal. - postgres --single to enforce recovery once and get the target cluster in a clean shutdown state. Both commands have been applying incorrect quoting rules, which could lead to failures when for example using a target data directory with unexpected characters like CRLFs. Those commands are now generated with PQExpBuffer, making use of string_utils.h to quote those commands as they should. We may extend those commands in the future with more options, so this makes any upcoming additions easier. This is arguably a bug fix, but nobody has complained about the existing code being a problem either, so no backpatch is done. Extracted from a larger patch by the same author. Author: Gunnar "Nick" Bluth Discussion: https://postgr.es/m/7c59265d-ac50-b0aa-ca1e-65e8bd27642a@pro-open.de
Diffstat (limited to 'src/backend/utils/adt/numeric.c')
0 files changed, 0 insertions, 0 deletions