From: Peter Eisentraut Date: Tue, 2 Jul 2019 22:18:43 +0000 (+0100) Subject: Remove redundant newlines from error messages X-Git-Tag: REL_12_BETA3~101 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=7956d7ac9811a6e97b3aef2ad00272c0b72dc7da;p=postgresql Remove redundant newlines from error messages These are no longer needed/allowed with the new logging API. --- diff --git a/src/bin/pg_basebackup/pg_basebackup.c b/src/bin/pg_basebackup/pg_basebackup.c index 63f554307c..15f43f9432 100644 --- a/src/bin/pg_basebackup/pg_basebackup.c +++ b/src/bin/pg_basebackup/pg_basebackup.c @@ -2236,7 +2236,7 @@ main(int argc, char **argv) format = 't'; else { - pg_log_error("invalid output format \"%s\", must be \"plain\" or \"tar\"\n", + pg_log_error("invalid output format \"%s\", must be \"plain\" or \"tar\"", optarg); exit(1); } @@ -2308,7 +2308,7 @@ main(int argc, char **argv) compresslevel = atoi(optarg); if (compresslevel < 0 || compresslevel > 9) { - pg_log_error("invalid compression level \"%s\"\n", optarg); + pg_log_error("invalid compression level \"%s\"", optarg); exit(1); } break; diff --git a/src/bin/pg_dump/pg_backup_tar.c b/src/bin/pg_dump/pg_backup_tar.c index 972318904b..0e547e83be 100644 --- a/src/bin/pg_dump/pg_backup_tar.c +++ b/src/bin/pg_dump/pg_backup_tar.c @@ -568,7 +568,7 @@ _tarReadRaw(ArchiveHandle *AH, void *buf, size_t len, TAR_MEMBER *th, FILE *fh) } } else - fatal("internal error -- neither th nor fh specified in tarReadRaw()\n"); + fatal("internal error -- neither th nor fh specified in tarReadRaw()"); } ctx->tarFHpos += res + used; diff --git a/src/bin/pg_dump/pg_dump.c b/src/bin/pg_dump/pg_dump.c index b07d58c4a8..1cd25adb6c 100644 --- a/src/bin/pg_dump/pg_dump.c +++ b/src/bin/pg_dump/pg_dump.c @@ -13484,7 +13484,7 @@ dumpCollation(Archive *fout, CollInfo *collinfo) /* to allow dumping pg_catalog; not accepted on input */ appendPQExpBufferStr(q, "default"); else - fatal("unrecognized collation provider: %s\n", + fatal("unrecognized collation provider: %s", collprovider); if (strcmp(PQgetvalue(res, 0, i_collisdeterministic), "f") == 0) diff --git a/src/bin/pg_rewind/pg_rewind.c b/src/bin/pg_rewind/pg_rewind.c index 6e77201be6..d378053de4 100644 --- a/src/bin/pg_rewind/pg_rewind.c +++ b/src/bin/pg_rewind/pg_rewind.c @@ -555,7 +555,7 @@ getTimelineHistory(ControlFileData *controlFile, int *nentries) else if (controlFile == &ControlFile_target) histfile = slurpFile(datadir_target, path, NULL); else - pg_fatal("invalid control file\n"); + pg_fatal("invalid control file"); history = rewind_parseTimeLineHistory(histfile, tli, nentries); pg_free(histfile);