aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorMichael Paquier <michael@paquier.xyz>2019-03-23 21:56:43 +0900
committerMichael Paquier <michael@paquier.xyz>2019-03-23 21:56:43 +0900
commit4ba96d1b82d694fead0ac709f9429cbb7ea89cb0 (patch)
tree3c9b950a171f4d94037b75b29bf9d26b30471e56 /src
parentfb50d3f03fe6876b878d636a312c2ccc1f4f99af (diff)
downloadpostgresql-4ba96d1b82d694fead0ac709f9429cbb7ea89cb0.tar.gz
postgresql-4ba96d1b82d694fead0ac709f9429cbb7ea89cb0.zip
Improve format of code and some error messages in pg_checksums
This makes the code more consistent with the surroundings. Author: Fabrízio de Royes Mello Discussion: https://postgr.es/m/CAFcNs+pXb_35r5feMU3-dWsWxXU=Yjq+spUsthFyGFbT0QcaKg@mail.gmail.com
Diffstat (limited to 'src')
-rw-r--r--src/bin/pg_checksums/pg_checksums.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/bin/pg_checksums/pg_checksums.c b/src/bin/pg_checksums/pg_checksums.c
index f9ab27c77c6..5c185ebed84 100644
--- a/src/bin/pg_checksums/pg_checksums.c
+++ b/src/bin/pg_checksums/pg_checksums.c
@@ -435,16 +435,18 @@ main(int argc, char *argv[])
fprintf(stderr, _("%s: data checksums are not enabled in cluster\n"), progname);
exit(1);
}
+
if (ControlFile->data_checksum_version == 0 &&
mode == PG_MODE_DISABLE)
{
- fprintf(stderr, _("%s: data checksums are already disabled in cluster.\n"), progname);
+ fprintf(stderr, _("%s: data checksums are already disabled in cluster\n"), progname);
exit(1);
}
+
if (ControlFile->data_checksum_version > 0 &&
mode == PG_MODE_ENABLE)
{
- fprintf(stderr, _("%s: data checksums are already enabled in cluster.\n"), progname);
+ fprintf(stderr, _("%s: data checksums are already enabled in cluster\n"), progname);
exit(1);
}