Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit 8649341

Browse files
committed
Refer to bug report address by symbol rather than hardcoding
Use the PACKAGE_BUGREPORT macro that is created by Autoconf for referring to the bug reporting address rather than hardcoding it everywhere. This makes it easier to change the address and it reduces translation work. Reviewed-by: Daniel Gustafsson <daniel@yesql.se> Discussion: https://www.postgresql.org/message-id/flat/8d389c5f-7fb5-8e48-9a4a-68cec44786fa%402ndquadrant.com
1 parent afb5465 commit 8649341

File tree

36 files changed

+39
-39
lines changed

36 files changed

+39
-39
lines changed

configure.in

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ PostgreSQL has apparently not been ported to your platform yet.
7979
To try a manual configuration, look into the src/template directory
8080
for a similar platform and use the '--with-template=' option.
8181

82-
Please also contact <pgsql-bugs@lists.postgresql.org> to see about
82+
Please also contact <]AC_PACKAGE_BUGREPORT[> to see about
8383
rectifying this. Include the above 'checking host system type...'
8484
line.
8585
*******************************************************************

contrib/oid2name/oid2name.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -219,8 +219,8 @@ help(const char *progname)
219219
" -p, --port=PORT database server port number\n"
220220
" -U, --username=USERNAME connect as specified database user\n"
221221
"\nThe default action is to show all database OIDs.\n\n"
222-
"Report bugs to <pgsql-bugs@lists.postgresql.org>.\n",
223-
progname, progname);
222+
"Report bugs to <%s>.\n",
223+
progname, progname, PACKAGE_BUGREPORT);
224224
}
225225

226226
/*

contrib/pg_standby/pg_standby.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -612,7 +612,7 @@ usage(void)
612612
" restore_command = 'pg_standby [OPTION]... ARCHIVELOCATION %%f %%p %%r'\n"
613613
"e.g.\n"
614614
" restore_command = 'pg_standby /mnt/server/archiverdir %%f %%p %%r'\n");
615-
printf("\nReport bugs to <pgsql-bugs@lists.postgresql.org>.\n");
615+
printf("\nReport bugs to <%s>.\n", PACKAGE_BUGREPORT);
616616
}
617617

618618
#ifndef WIN32

contrib/vacuumlo/vacuumlo.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -436,7 +436,7 @@ usage(const char *progname)
436436
printf(" -w, --no-password never prompt for password\n");
437437
printf(" -W, --password force password prompt\n");
438438
printf("\n");
439-
printf("Report bugs to <pgsql-bugs@lists.postgresql.org>.\n");
439+
printf("Report bugs to <%s>.\n", PACKAGE_BUGREPORT);
440440
}
441441

442442

src/backend/main/main.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -359,7 +359,7 @@ help(const char *progname)
359359
printf(_("\nPlease read the documentation for the complete list of run-time\n"
360360
"configuration settings and how to set them on the command line or in\n"
361361
"the configuration file.\n\n"
362-
"Report bugs to <pgsql-bugs@lists.postgresql.org>.\n"));
362+
"Report bugs to <%s>.\n"), PACKAGE_BUGREPORT);
363363
}
364364

365365

src/backend/postmaster/postmaster.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5141,7 +5141,7 @@ ExitPostmaster(int status)
51415141
ereport(LOG,
51425142
(errcode(ERRCODE_INTERNAL_ERROR),
51435143
errmsg_internal("postmaster became multithreaded"),
5144-
errdetail("Please report this to <pgsql-bugs@lists.postgresql.org>.")));
5144+
errdetail("Please report this to <%s>.", PACKAGE_BUGREPORT)));
51455145
#endif
51465146

51475147
/* should cleanup shared memory and kill all backends */

src/bin/initdb/initdb.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2322,7 +2322,7 @@ usage(const char *progname)
23222322
printf(_(" -?, --help show this help, then exit\n"));
23232323
printf(_("\nIf the data directory is not specified, the environment variable PGDATA\n"
23242324
"is used.\n"));
2325-
printf(_("\nReport bugs to <pgsql-bugs@lists.postgresql.org>.\n"));
2325+
printf(_("\nReport bugs to <%s>.\n"), PACKAGE_BUGREPORT);
23262326
}
23272327

23282328
static void

src/bin/pg_archivecleanup/pg_archivecleanup.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -269,7 +269,7 @@ usage(void)
269269
"Or for use as a standalone archive cleaner:\n"
270270
"e.g.\n"
271271
" pg_archivecleanup /mnt/server/archiverdir 000000010000000000000010.00000020.backup\n"));
272-
printf(_("\nReport bugs to <pgsql-bugs@lists.postgresql.org>.\n"));
272+
printf(_("\nReport bugs to <%s>.\n"), PACKAGE_BUGREPORT);
273273
}
274274

275275
/*------------ MAIN ----------------------------------------*/

src/bin/pg_basebackup/pg_basebackup.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -396,7 +396,7 @@ usage(void)
396396
printf(_(" -U, --username=NAME connect as specified database user\n"));
397397
printf(_(" -w, --no-password never prompt for password\n"));
398398
printf(_(" -W, --password force password prompt (should happen automatically)\n"));
399-
printf(_("\nReport bugs to <pgsql-bugs@lists.postgresql.org>.\n"));
399+
printf(_("\nReport bugs to <%s>.\n"), PACKAGE_BUGREPORT);
400400
}
401401

402402

src/bin/pg_basebackup/pg_receivewal.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,7 @@ usage(void)
102102
printf(_("\nOptional actions:\n"));
103103
printf(_(" --create-slot create a new replication slot (for the slot's name see --slot)\n"));
104104
printf(_(" --drop-slot drop the replication slot (for the slot's name see --slot)\n"));
105-
printf(_("\nReport bugs to <pgsql-bugs@lists.postgresql.org>.\n"));
105+
printf(_("\nReport bugs to <%s>.\n"), PACKAGE_BUGREPORT);
106106
}
107107

108108
static bool

src/bin/pg_basebackup/pg_recvlogical.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,7 @@ usage(void)
103103
printf(_(" -U, --username=NAME connect as specified database user\n"));
104104
printf(_(" -w, --no-password never prompt for password\n"));
105105
printf(_(" -W, --password force password prompt (should happen automatically)\n"));
106-
printf(_("\nReport bugs to <pgsql-bugs@lists.postgresql.org>.\n"));
106+
printf(_("\nReport bugs to <%s>.\n"), PACKAGE_BUGREPORT);
107107
}
108108

109109
/*

src/bin/pg_checksums/pg_checksums.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,7 @@ usage(void)
8888
printf(_(" -?, --help show this help, then exit\n"));
8989
printf(_("\nIf no data directory (DATADIR) is specified, "
9090
"the environment variable PGDATA\nis used.\n\n"));
91-
printf(_("Report bugs to <pgsql-bugs@lists.postgresql.org>.\n"));
91+
printf(_("Report bugs to <%s>.\n"), PACKAGE_BUGREPORT);
9292
}
9393

9494
/*

src/bin/pg_config/pg_config.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,7 @@ help(void)
102102
printf(_(" --version show the PostgreSQL version\n"));
103103
printf(_(" -?, --help show this help, then exit\n"));
104104
printf(_("\nWith no arguments, all known items are shown.\n\n"));
105-
printf(_("Report bugs to <pgsql-bugs@lists.postgresql.org>.\n"));
105+
printf(_("Report bugs to <%s>.\n"), PACKAGE_BUGREPORT);
106106
}
107107

108108
static void

src/bin/pg_controldata/pg_controldata.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ usage(const char *progname)
4141
printf(_(" -?, --help show this help, then exit\n"));
4242
printf(_("\nIf no data directory (DATADIR) is specified, "
4343
"the environment variable PGDATA\nis used.\n\n"));
44-
printf(_("Report bugs to <pgsql-bugs@lists.postgresql.org>.\n"));
44+
printf(_("Report bugs to <%s>.\n"), PACKAGE_BUGREPORT);
4545
}
4646

4747

src/bin/pg_ctl/pg_ctl.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2095,7 +2095,7 @@ do_help(void)
20952095
printf(_(" demand start service on demand\n"));
20962096
#endif
20972097

2098-
printf(_("\nReport bugs to <pgsql-bugs@lists.postgresql.org>.\n"));
2098+
printf(_("\nReport bugs to <%s>.\n"), PACKAGE_BUGREPORT);
20992099
}
21002100

21012101

src/bin/pg_dump/pg_dump.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1047,7 +1047,7 @@ help(const char *progname)
10471047

10481048
printf(_("\nIf no database name is supplied, then the PGDATABASE environment\n"
10491049
"variable value is used.\n\n"));
1050-
printf(_("Report bugs to <pgsql-bugs@lists.postgresql.org>.\n"));
1050+
printf(_("Report bugs to <%s>.\n"), PACKAGE_BUGREPORT);
10511051
}
10521052

10531053
static void

src/bin/pg_dump/pg_dumpall.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -670,7 +670,7 @@ help(void)
670670

671671
printf(_("\nIf -f/--file is not used, then the SQL script will be written to the standard\n"
672672
"output.\n\n"));
673-
printf(_("Report bugs to <pgsql-bugs@lists.postgresql.org>.\n"));
673+
printf(_("Report bugs to <%s>.\n"), PACKAGE_BUGREPORT);
674674
}
675675

676676

src/bin/pg_dump/pg_restore.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -519,5 +519,5 @@ usage(const char *progname)
519519
"The options -I, -n, -N, -P, -t, -T, and --section can be combined and specified\n"
520520
"multiple times to select multiple objects.\n"));
521521
printf(_("\nIf no input file name is supplied, then standard input is used.\n\n"));
522-
printf(_("Report bugs to <pgsql-bugs@lists.postgresql.org>.\n"));
522+
printf(_("Report bugs to <%s>.\n"), PACKAGE_BUGREPORT);
523523
}

src/bin/pg_resetwal/pg_resetwal.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1223,5 +1223,5 @@ usage(void)
12231223
printf(_(" -x, --next-transaction-id=XID set next transaction ID\n"));
12241224
printf(_(" --wal-segsize=SIZE size of WAL segments, in megabytes\n"));
12251225
printf(_(" -?, --help show this help, then exit\n"));
1226-
printf(_("\nReport bugs to <pgsql-bugs@lists.postgresql.org>.\n"));
1226+
printf(_("\nReport bugs to <%s>.\n"), PACKAGE_BUGREPORT);
12271227
}

src/bin/pg_rewind/pg_rewind.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@ usage(const char *progname)
8787
printf(_(" --debug write a lot of debug messages\n"));
8888
printf(_(" -V, --version output version information, then exit\n"));
8989
printf(_(" -?, --help show this help, then exit\n"));
90-
printf(_("\nReport bugs to <pgsql-bugs@lists.postgresql.org>.\n"));
90+
printf(_("\nReport bugs to <%s>.\n"), PACKAGE_BUGREPORT);
9191
}
9292

9393

src/bin/pg_upgrade/option.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -336,7 +336,7 @@ usage(void)
336336
" C:\\> set PGBINNEW=newCluster/bin\n"
337337
" C:\\> pg_upgrade\n"));
338338
#endif
339-
printf(_("\nReport bugs to <pgsql-bugs@lists.postgresql.org>.\n"));
339+
printf(_("\nReport bugs to <%s>.\n"), PACKAGE_BUGREPORT);
340340
}
341341

342342

src/bin/pg_waldump/pg_waldump.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -730,7 +730,7 @@ usage(void)
730730
printf(_(" -z, --stats[=record] show statistics instead of records\n"
731731
" (optionally, show per-record statistics)\n"));
732732
printf(_(" -?, --help show this help, then exit\n"));
733-
printf(_("\nReport bugs to <pgsql-bugs@lists.postgresql.org>.\n"));
733+
printf(_("\nReport bugs to <%s>.\n"), PACKAGE_BUGREPORT);
734734
}
735735

736736
int

src/bin/pgbench/pgbench.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -681,8 +681,8 @@ usage(void)
681681
" -V, --version output version information, then exit\n"
682682
" -?, --help show this help, then exit\n"
683683
"\n"
684-
"Report bugs to <pgsql-bugs@lists.postgresql.org>.\n",
685-
progname, progname);
684+
"Report bugs to <%s>.\n",
685+
progname, progname, PACKAGE_BUGREPORT);
686686
}
687687

688688
/* return whether str matches "^\s*[-+]?[0-9]+$" */

src/bin/psql/help.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -144,7 +144,7 @@ usage(unsigned short int pager)
144144
fprintf(output, _("\nFor more information, type \"\\?\" (for internal commands) or \"\\help\" (for SQL\n"
145145
"commands) from within psql, or consult the psql section in the PostgreSQL\n"
146146
"documentation.\n\n"));
147-
fprintf(output, _("Report bugs to <pgsql-bugs@lists.postgresql.org>.\n"));
147+
fprintf(output, _("Report bugs to <%s>.\n"), PACKAGE_BUGREPORT);
148148

149149
ClosePager(output);
150150
}

src/bin/scripts/clusterdb.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -291,5 +291,5 @@ help(const char *progname)
291291
printf(_(" -W, --password force password prompt\n"));
292292
printf(_(" --maintenance-db=DBNAME alternate maintenance database\n"));
293293
printf(_("\nRead the description of the SQL command CLUSTER for details.\n"));
294-
printf(_("\nReport bugs to <pgsql-bugs@lists.postgresql.org>.\n"));
294+
printf(_("\nReport bugs to <%s>.\n"), PACKAGE_BUGREPORT);
295295
}

src/bin/scripts/createdb.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -277,5 +277,5 @@ help(const char *progname)
277277
printf(_(" -W, --password force password prompt\n"));
278278
printf(_(" --maintenance-db=DBNAME alternate maintenance database\n"));
279279
printf(_("\nBy default, a database with the same name as the current user is created.\n"));
280-
printf(_("\nReport bugs to <pgsql-bugs@lists.postgresql.org>.\n"));
280+
printf(_("\nReport bugs to <%s>.\n"), PACKAGE_BUGREPORT);
281281
}

src/bin/scripts/createuser.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -375,5 +375,5 @@ help(const char *progname)
375375
printf(_(" -U, --username=USERNAME user name to connect as (not the one to create)\n"));
376376
printf(_(" -w, --no-password never prompt for password\n"));
377377
printf(_(" -W, --password force password prompt\n"));
378-
printf(_("\nReport bugs to <pgsql-bugs@lists.postgresql.org>.\n"));
378+
printf(_("\nReport bugs to <%s>.\n"), PACKAGE_BUGREPORT);
379379
}

src/bin/scripts/dropdb.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -177,5 +177,5 @@ help(const char *progname)
177177
printf(_(" -w, --no-password never prompt for password\n"));
178178
printf(_(" -W, --password force password prompt\n"));
179179
printf(_(" --maintenance-db=DBNAME alternate maintenance database\n"));
180-
printf(_("\nReport bugs to <pgsql-bugs@lists.postgresql.org>.\n"));
180+
printf(_("\nReport bugs to <%s>.\n"), PACKAGE_BUGREPORT);
181181
}

src/bin/scripts/dropuser.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -175,5 +175,5 @@ help(const char *progname)
175175
printf(_(" -U, --username=USERNAME user name to connect as (not the one to drop)\n"));
176176
printf(_(" -w, --no-password never prompt for password\n"));
177177
printf(_(" -W, --password force password prompt\n"));
178-
printf(_("\nReport bugs to <pgsql-bugs@lists.postgresql.org>.\n"));
178+
printf(_("\nReport bugs to <%s>.\n"), PACKAGE_BUGREPORT);
179179
}

src/bin/scripts/pg_isready.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -235,5 +235,5 @@ help(const char *progname)
235235
printf(_(" -p, --port=PORT database server port\n"));
236236
printf(_(" -t, --timeout=SECS seconds to wait when attempting connection, 0 disables (default: %s)\n"), DEFAULT_CONNECT_TIMEOUT);
237237
printf(_(" -U, --username=USERNAME user name to connect as\n"));
238-
printf(_("\nReport bugs to <pgsql-bugs@lists.postgresql.org>.\n"));
238+
printf(_("\nReport bugs to <%s>.\n"), PACKAGE_BUGREPORT);
239239
}

src/bin/scripts/reindexdb.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -774,5 +774,5 @@ help(const char *progname)
774774
printf(_(" -W, --password force password prompt\n"));
775775
printf(_(" --maintenance-db=DBNAME alternate maintenance database\n"));
776776
printf(_("\nRead the description of the SQL command REINDEX for details.\n"));
777-
printf(_("\nReport bugs to <pgsql-bugs@lists.postgresql.org>.\n"));
777+
printf(_("\nReport bugs to <%s>.\n"), PACKAGE_BUGREPORT);
778778
}

src/bin/scripts/vacuumdb.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -949,5 +949,5 @@ help(const char *progname)
949949
printf(_(" -W, --password force password prompt\n"));
950950
printf(_(" --maintenance-db=DBNAME alternate maintenance database\n"));
951951
printf(_("\nRead the description of the SQL command VACUUM for details.\n"));
952-
printf(_("\nReport bugs to <pgsql-bugs@lists.postgresql.org>.\n"));
952+
printf(_("\nReport bugs to <%s>.\n"), PACKAGE_BUGREPORT);
953953
}

src/interfaces/ecpg/preproc/ecpg.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ help(const char *progname)
5858
printf(_(" -?, --help show this help, then exit\n"));
5959
printf(_("\nIf no output file is specified, the name is formed by adding .c to the\n"
6060
"input file name, after stripping off .pgc if present.\n"));
61-
printf(_("\nReport bugs to <pgsql-bugs@lists.postgresql.org>.\n"));
61+
printf(_("\nReport bugs to <%s>.\n"), PACKAGE_BUGREPORT);
6262
}
6363

6464
static void

src/interfaces/ecpg/preproc/pgc.l

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1429,7 +1429,7 @@ cppline {space}*#([^i][A-Za-z]*|{if}|{ifdef}|{ifndef}|{import})((\/\*[^*/]*\*+
14291429
}
14301430
}
14311431

1432-
<INITIAL>{other}|\n { mmfatal(PARSE_ERROR, "internal error: unreachable state; please report this to <pgsql-bugs@lists.postgresql.org>"); }
1432+
<INITIAL>{other}|\n { mmfatal(PARSE_ERROR, "internal error: unreachable state; please report this to <%s>", PACKAGE_BUGREPORT); }
14331433

14341434
%%
14351435

src/interfaces/ecpg/preproc/type.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -301,7 +301,7 @@ ECPGdump_a_type(FILE *o, const char *name, struct ECPGtype *type, const int brac
301301
break;
302302
default:
303303
if (!IS_SIMPLE_TYPE(type->u.element->type))
304-
base_yyerror("internal error: unknown datatype, please report this to <pgsql-bugs@lists.postgresql.org>");
304+
base_yyerror("internal error: unknown datatype, please report this to <" PACKAGE_BUGREPORT ">");
305305

306306
ECPGdump_a_simple(o, name,
307307
type->u.element->type,
@@ -672,7 +672,7 @@ ECPGfree_type(struct ECPGtype *type)
672672
break;
673673
default:
674674
if (!IS_SIMPLE_TYPE(type->u.element->type))
675-
base_yyerror("internal error: unknown datatype, please report this to <pgsql-bugs@lists.postgresql.org>");
675+
base_yyerror("internal error: unknown datatype, please report this to <" PACKAGE_BUGREPORT ">");
676676

677677
free(type->u.element);
678678
}

src/test/regress/pg_regress.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2071,7 +2071,7 @@ help(void)
20712071
printf(_("The exit status is 0 if all tests passed, 1 if some tests failed, and 2\n"));
20722072
printf(_("if the tests could not be run for some reason.\n"));
20732073
printf(_("\n"));
2074-
printf(_("Report bugs to <pgsql-bugs@lists.postgresql.org>.\n"));
2074+
printf(_("Report bugs to <%s>.\n"), PACKAGE_BUGREPORT);
20752075
}
20762076

20772077
int

0 commit comments

Comments
 (0)