mirror of
https://github.com/postgres/postgres.git
synced 2025-07-17 06:41:09 +03:00
Use _() macro consistently rather than gettext(). Add translation
macros around strings that were missing them.
This commit is contained in:
@ -8,7 +8,7 @@
|
||||
* Portions Copyright (c) 1994, Regents of the University of California
|
||||
*
|
||||
* IDENTIFICATION
|
||||
* $PostgreSQL: pgsql/src/backend/catalog/dependency.c,v 1.41 2004/12/31 21:59:38 pgsql Exp $
|
||||
* $PostgreSQL: pgsql/src/backend/catalog/dependency.c,v 1.42 2005/02/22 04:35:34 momjian Exp $
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
@ -1424,18 +1424,18 @@ getObjectDescription(const ObjectAddress *object)
|
||||
case OCLASS_CLASS:
|
||||
getRelationDescription(&buffer, object->objectId);
|
||||
if (object->objectSubId != 0)
|
||||
appendStringInfo(&buffer, gettext(" column %s"),
|
||||
appendStringInfo(&buffer, _(" column %s"),
|
||||
get_relid_attribute_name(object->objectId,
|
||||
object->objectSubId));
|
||||
break;
|
||||
|
||||
case OCLASS_PROC:
|
||||
appendStringInfo(&buffer, gettext("function %s"),
|
||||
appendStringInfo(&buffer, _("function %s"),
|
||||
format_procedure(object->objectId));
|
||||
break;
|
||||
|
||||
case OCLASS_TYPE:
|
||||
appendStringInfo(&buffer, gettext("type %s"),
|
||||
appendStringInfo(&buffer, _("type %s"),
|
||||
format_type_be(object->objectId));
|
||||
break;
|
||||
|
||||
@ -1465,7 +1465,7 @@ getObjectDescription(const ObjectAddress *object)
|
||||
|
||||
castForm = (Form_pg_cast) GETSTRUCT(tup);
|
||||
|
||||
appendStringInfo(&buffer, gettext("cast from %s to %s"),
|
||||
appendStringInfo(&buffer, _("cast from %s to %s"),
|
||||
format_type_be(castForm->castsource),
|
||||
format_type_be(castForm->casttarget));
|
||||
|
||||
@ -1502,13 +1502,13 @@ getObjectDescription(const ObjectAddress *object)
|
||||
|
||||
if (OidIsValid(con->conrelid))
|
||||
{
|
||||
appendStringInfo(&buffer, gettext("constraint %s on "),
|
||||
appendStringInfo(&buffer, _("constraint %s on "),
|
||||
NameStr(con->conname));
|
||||
getRelationDescription(&buffer, con->conrelid);
|
||||
}
|
||||
else
|
||||
{
|
||||
appendStringInfo(&buffer, gettext("constraint %s"),
|
||||
appendStringInfo(&buffer, _("constraint %s"),
|
||||
NameStr(con->conname));
|
||||
}
|
||||
|
||||
@ -1527,7 +1527,7 @@ getObjectDescription(const ObjectAddress *object)
|
||||
if (!HeapTupleIsValid(conTup))
|
||||
elog(ERROR, "cache lookup failed for conversion %u",
|
||||
object->objectId);
|
||||
appendStringInfo(&buffer, gettext("conversion %s"),
|
||||
appendStringInfo(&buffer, _("conversion %s"),
|
||||
NameStr(((Form_pg_conversion) GETSTRUCT(conTup))->conname));
|
||||
ReleaseSysCache(conTup);
|
||||
break;
|
||||
@ -1564,7 +1564,7 @@ getObjectDescription(const ObjectAddress *object)
|
||||
colobject.objectId = attrdef->adrelid;
|
||||
colobject.objectSubId = attrdef->adnum;
|
||||
|
||||
appendStringInfo(&buffer, gettext("default for %s"),
|
||||
appendStringInfo(&buffer, _("default for %s"),
|
||||
getObjectDescription(&colobject));
|
||||
|
||||
systable_endscan(adscan);
|
||||
@ -1582,14 +1582,14 @@ getObjectDescription(const ObjectAddress *object)
|
||||
if (!HeapTupleIsValid(langTup))
|
||||
elog(ERROR, "cache lookup failed for language %u",
|
||||
object->objectId);
|
||||
appendStringInfo(&buffer, gettext("language %s"),
|
||||
appendStringInfo(&buffer, _("language %s"),
|
||||
NameStr(((Form_pg_language) GETSTRUCT(langTup))->lanname));
|
||||
ReleaseSysCache(langTup);
|
||||
break;
|
||||
}
|
||||
|
||||
case OCLASS_OPERATOR:
|
||||
appendStringInfo(&buffer, gettext("operator %s"),
|
||||
appendStringInfo(&buffer, _("operator %s"),
|
||||
format_operator(object->objectId));
|
||||
break;
|
||||
|
||||
@ -1623,7 +1623,7 @@ getObjectDescription(const ObjectAddress *object)
|
||||
else
|
||||
nspname = get_namespace_name(opcForm->opcnamespace);
|
||||
|
||||
appendStringInfo(&buffer, gettext("operator class %s for access method %s"),
|
||||
appendStringInfo(&buffer, _("operator class %s for access method %s"),
|
||||
quote_qualified_identifier(nspname,
|
||||
NameStr(opcForm->opcname)),
|
||||
NameStr(amForm->amname));
|
||||
@ -1659,7 +1659,7 @@ getObjectDescription(const ObjectAddress *object)
|
||||
|
||||
rule = (Form_pg_rewrite) GETSTRUCT(tup);
|
||||
|
||||
appendStringInfo(&buffer, gettext("rule %s on "),
|
||||
appendStringInfo(&buffer, _("rule %s on "),
|
||||
NameStr(rule->rulename));
|
||||
getRelationDescription(&buffer, rule->ev_class);
|
||||
|
||||
@ -1694,7 +1694,7 @@ getObjectDescription(const ObjectAddress *object)
|
||||
|
||||
trig = (Form_pg_trigger) GETSTRUCT(tup);
|
||||
|
||||
appendStringInfo(&buffer, gettext("trigger %s on "),
|
||||
appendStringInfo(&buffer, _("trigger %s on "),
|
||||
NameStr(trig->tgname));
|
||||
getRelationDescription(&buffer, trig->tgrelid);
|
||||
|
||||
@ -1711,7 +1711,7 @@ getObjectDescription(const ObjectAddress *object)
|
||||
if (!nspname)
|
||||
elog(ERROR, "cache lookup failed for namespace %u",
|
||||
object->objectId);
|
||||
appendStringInfo(&buffer, gettext("schema %s"), nspname);
|
||||
appendStringInfo(&buffer, _("schema %s"), nspname);
|
||||
break;
|
||||
}
|
||||
|
||||
@ -1755,40 +1755,40 @@ getRelationDescription(StringInfo buffer, Oid relid)
|
||||
switch (relForm->relkind)
|
||||
{
|
||||
case RELKIND_RELATION:
|
||||
appendStringInfo(buffer, gettext("table %s"),
|
||||
appendStringInfo(buffer, _("table %s"),
|
||||
relname);
|
||||
break;
|
||||
case RELKIND_INDEX:
|
||||
appendStringInfo(buffer, gettext("index %s"),
|
||||
appendStringInfo(buffer, _("index %s"),
|
||||
relname);
|
||||
break;
|
||||
case RELKIND_SPECIAL:
|
||||
appendStringInfo(buffer, gettext("special system relation %s"),
|
||||
appendStringInfo(buffer, _("special system relation %s"),
|
||||
relname);
|
||||
break;
|
||||
case RELKIND_SEQUENCE:
|
||||
appendStringInfo(buffer, gettext("sequence %s"),
|
||||
appendStringInfo(buffer, _("sequence %s"),
|
||||
relname);
|
||||
break;
|
||||
case RELKIND_UNCATALOGED:
|
||||
appendStringInfo(buffer, gettext("uncataloged table %s"),
|
||||
appendStringInfo(buffer, _("uncataloged table %s"),
|
||||
relname);
|
||||
break;
|
||||
case RELKIND_TOASTVALUE:
|
||||
appendStringInfo(buffer, gettext("toast table %s"),
|
||||
appendStringInfo(buffer, _("toast table %s"),
|
||||
relname);
|
||||
break;
|
||||
case RELKIND_VIEW:
|
||||
appendStringInfo(buffer, gettext("view %s"),
|
||||
appendStringInfo(buffer, _("view %s"),
|
||||
relname);
|
||||
break;
|
||||
case RELKIND_COMPOSITE_TYPE:
|
||||
appendStringInfo(buffer, gettext("composite type %s"),
|
||||
appendStringInfo(buffer, _("composite type %s"),
|
||||
relname);
|
||||
break;
|
||||
default:
|
||||
/* shouldn't get here */
|
||||
appendStringInfo(buffer, gettext("relation %s"),
|
||||
appendStringInfo(buffer, _("relation %s"),
|
||||
relname);
|
||||
break;
|
||||
}
|
||||
|
@ -8,7 +8,7 @@
|
||||
*
|
||||
*
|
||||
* IDENTIFICATION
|
||||
* $PostgreSQL: pgsql/src/backend/libpq/auth.c,v 1.122 2005/01/12 21:37:53 tgl Exp $
|
||||
* $PostgreSQL: pgsql/src/backend/libpq/auth.c,v 1.123 2005/02/22 04:35:57 momjian Exp $
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
@ -449,7 +449,7 @@ ClientAuthentication(Port *port)
|
||||
(errcode(ERRCODE_INVALID_AUTHORIZATION_SPECIFICATION),
|
||||
errmsg("no pg_hba.conf entry for host \"%s\", user \"%s\", database \"%s\", %s",
|
||||
hostinfo, port->user_name, port->database_name,
|
||||
port->ssl ? gettext("SSL on") : gettext("SSL off"))));
|
||||
port->ssl ? _("SSL on") : _("SSL off"))));
|
||||
#else
|
||||
ereport(FATAL,
|
||||
(errcode(ERRCODE_INVALID_AUTHORIZATION_SPECIFICATION),
|
||||
|
@ -30,7 +30,7 @@
|
||||
* Portions Copyright (c) 1996-2005, PostgreSQL Global Development Group
|
||||
* Portions Copyright (c) 1994, Regents of the University of California
|
||||
*
|
||||
* $PostgreSQL: pgsql/src/backend/libpq/pqcomm.c,v 1.175 2005/01/12 16:38:17 tgl Exp $
|
||||
* $PostgreSQL: pgsql/src/backend/libpq/pqcomm.c,v 1.176 2005/02/22 04:35:57 momjian Exp $
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
@ -308,21 +308,21 @@ StreamServerPort(int family, char *hostName, unsigned short portNumber,
|
||||
switch (addr->ai_family)
|
||||
{
|
||||
case AF_INET:
|
||||
familyDesc = gettext("IPv4");
|
||||
familyDesc = _("IPv4");
|
||||
break;
|
||||
#ifdef HAVE_IPV6
|
||||
case AF_INET6:
|
||||
familyDesc = gettext("IPv6");
|
||||
familyDesc = _("IPv6");
|
||||
break;
|
||||
#endif
|
||||
#ifdef HAVE_UNIX_SOCKETS
|
||||
case AF_UNIX:
|
||||
familyDesc = gettext("Unix");
|
||||
familyDesc = _("Unix");
|
||||
break;
|
||||
#endif
|
||||
default:
|
||||
snprintf(familyDescBuf, sizeof(familyDescBuf),
|
||||
gettext("unrecognized address family %d"),
|
||||
_("unrecognized address family %d"),
|
||||
addr->ai_family);
|
||||
familyDesc = familyDescBuf;
|
||||
break;
|
||||
|
@ -10,7 +10,7 @@
|
||||
* Portions Copyright (c) 1994, Regents of the University of California
|
||||
*
|
||||
* IDENTIFICATION
|
||||
* $PostgreSQL: pgsql/src/backend/parser/scan.l,v 1.119 2004/12/31 22:00:27 pgsql Exp $
|
||||
* $PostgreSQL: pgsql/src/backend/parser/scan.l,v 1.120 2005/02/22 04:36:22 momjian Exp $
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
@ -618,7 +618,7 @@ yyerror(const char *message)
|
||||
ereport(ERROR,
|
||||
(errcode(ERRCODE_SYNTAX_ERROR),
|
||||
/* translator: %s is typically "syntax error" */
|
||||
errmsg("%s at end of input", gettext(message)),
|
||||
errmsg("%s at end of input", _(message)),
|
||||
errposition(cursorpos)));
|
||||
}
|
||||
else
|
||||
@ -626,7 +626,7 @@ yyerror(const char *message)
|
||||
ereport(ERROR,
|
||||
(errcode(ERRCODE_SYNTAX_ERROR),
|
||||
/* translator: first %s is typically "syntax error" */
|
||||
errmsg("%s at or near \"%s\"", gettext(message), loc),
|
||||
errmsg("%s at or near \"%s\"", _(message), loc),
|
||||
errposition(cursorpos)));
|
||||
}
|
||||
}
|
||||
|
@ -37,7 +37,7 @@
|
||||
*
|
||||
*
|
||||
* IDENTIFICATION
|
||||
* $PostgreSQL: pgsql/src/backend/postmaster/postmaster.c,v 1.444 2005/02/20 02:21:54 tgl Exp $
|
||||
* $PostgreSQL: pgsql/src/backend/postmaster/postmaster.c,v 1.445 2005/02/22 04:36:36 momjian Exp $
|
||||
*
|
||||
* NOTES
|
||||
*
|
||||
@ -1065,35 +1065,35 @@ pmdaemonize(void)
|
||||
static void
|
||||
usage(const char *progname)
|
||||
{
|
||||
printf(gettext("%s is the PostgreSQL server.\n\n"), progname);
|
||||
printf(gettext("Usage:\n %s [OPTION]...\n\n"), progname);
|
||||
printf(gettext("Options:\n"));
|
||||
printf(_("%s is the PostgreSQL server.\n\n"), progname);
|
||||
printf(_("Usage:\n %s [OPTION]...\n\n"), progname);
|
||||
printf(_("Options:\n"));
|
||||
#ifdef USE_ASSERT_CHECKING
|
||||
printf(gettext(" -A 1|0 enable/disable run-time assert checking\n"));
|
||||
printf(_(" -A 1|0 enable/disable run-time assert checking\n"));
|
||||
#endif
|
||||
printf(gettext(" -B NBUFFERS number of shared buffers\n"));
|
||||
printf(gettext(" -c NAME=VALUE set run-time parameter\n"));
|
||||
printf(gettext(" -d 1-5 debugging level\n"));
|
||||
printf(gettext(" -D DATADIR database directory\n"));
|
||||
printf(gettext(" -F turn fsync off\n"));
|
||||
printf(gettext(" -h HOSTNAME host name or IP address to listen on\n"));
|
||||
printf(gettext(" -i enable TCP/IP connections\n"));
|
||||
printf(gettext(" -k DIRECTORY Unix-domain socket location\n"));
|
||||
printf(_(" -B NBUFFERS number of shared buffers\n"));
|
||||
printf(_(" -c NAME=VALUE set run-time parameter\n"));
|
||||
printf(_(" -d 1-5 debugging level\n"));
|
||||
printf(_(" -D DATADIR database directory\n"));
|
||||
printf(_(" -F turn fsync off\n"));
|
||||
printf(_(" -h HOSTNAME host name or IP address to listen on\n"));
|
||||
printf(_(" -i enable TCP/IP connections\n"));
|
||||
printf(_(" -k DIRECTORY Unix-domain socket location\n"));
|
||||
#ifdef USE_SSL
|
||||
printf(gettext(" -l enable SSL connections\n"));
|
||||
printf(_(" -l enable SSL connections\n"));
|
||||
#endif
|
||||
printf(gettext(" -N MAX-CONNECT maximum number of allowed connections\n"));
|
||||
printf(gettext(" -o OPTIONS pass \"OPTIONS\" to each server process\n"));
|
||||
printf(gettext(" -p PORT port number to listen on\n"));
|
||||
printf(gettext(" -S silent mode (start in background without logging output)\n"));
|
||||
printf(gettext(" --help show this help, then exit\n"));
|
||||
printf(gettext(" --version output version information, then exit\n"));
|
||||
printf(_(" -N MAX-CONNECT maximum number of allowed connections\n"));
|
||||
printf(_(" -o OPTIONS pass \"OPTIONS\" to each server process\n"));
|
||||
printf(_(" -p PORT port number to listen on\n"));
|
||||
printf(_(" -S silent mode (start in background without logging output)\n"));
|
||||
printf(_(" --help show this help, then exit\n"));
|
||||
printf(_(" --version output version information, then exit\n"));
|
||||
|
||||
printf(gettext("\nDeveloper options:\n"));
|
||||
printf(gettext(" -n do not reinitialize shared memory after abnormal exit\n"));
|
||||
printf(gettext(" -s send SIGSTOP to all backend servers if one dies\n"));
|
||||
printf(_("\nDeveloper options:\n"));
|
||||
printf(_(" -n do not reinitialize shared memory after abnormal exit\n"));
|
||||
printf(_(" -s send SIGSTOP to all backend servers if one dies\n"));
|
||||
|
||||
printf(gettext("\nPlease read the documentation for the complete list of run-time\n"
|
||||
printf(_("\nPlease read the documentation for the complete list of run-time\n"
|
||||
"configuration settings and how to set them on the command line or in\n"
|
||||
"the configuration file.\n\n"
|
||||
"Report bugs to <pgsql-bugs@postgresql.org>.\n"));
|
||||
@ -1993,7 +1993,7 @@ reaper(SIGNAL_ARGS)
|
||||
StartupPID = 0;
|
||||
if (exitstatus != 0)
|
||||
{
|
||||
LogChildExit(LOG, gettext("startup process"),
|
||||
LogChildExit(LOG, _("startup process"),
|
||||
pid, exitstatus);
|
||||
ereport(LOG,
|
||||
(errmsg("aborting startup due to startup process failure")));
|
||||
@ -2067,7 +2067,7 @@ reaper(SIGNAL_ARGS)
|
||||
* Any unexpected exit of the bgwriter is treated as a crash.
|
||||
*/
|
||||
HandleChildCrash(pid, exitstatus,
|
||||
gettext("background writer process"));
|
||||
_("background writer process"));
|
||||
continue;
|
||||
}
|
||||
|
||||
@ -2080,7 +2080,7 @@ reaper(SIGNAL_ARGS)
|
||||
{
|
||||
PgArchPID = 0;
|
||||
if (exitstatus != 0)
|
||||
LogChildExit(LOG, gettext("archiver process"),
|
||||
LogChildExit(LOG, _("archiver process"),
|
||||
pid, exitstatus);
|
||||
if (XLogArchivingActive() &&
|
||||
StartupPID == 0 && !FatalError && Shutdown == NoShutdown)
|
||||
@ -2097,7 +2097,7 @@ reaper(SIGNAL_ARGS)
|
||||
{
|
||||
PgStatPID = 0;
|
||||
if (exitstatus != 0)
|
||||
LogChildExit(LOG, gettext("statistics collector process"),
|
||||
LogChildExit(LOG, _("statistics collector process"),
|
||||
pid, exitstatus);
|
||||
if (StartupPID == 0 && !FatalError && Shutdown == NoShutdown)
|
||||
PgStatPID = pgstat_start();
|
||||
@ -2111,7 +2111,7 @@ reaper(SIGNAL_ARGS)
|
||||
/* for safety's sake, launch new logger *first* */
|
||||
SysLoggerPID = SysLogger_Start();
|
||||
if (exitstatus != 0)
|
||||
LogChildExit(LOG, gettext("system logger process"),
|
||||
LogChildExit(LOG, _("system logger process"),
|
||||
pid, exitstatus);
|
||||
continue;
|
||||
}
|
||||
@ -2178,7 +2178,7 @@ CleanupBackend(int pid,
|
||||
{
|
||||
Dlelem *curr;
|
||||
|
||||
LogChildExit(DEBUG2, gettext("server process"), pid, exitstatus);
|
||||
LogChildExit(DEBUG2, _("server process"), pid, exitstatus);
|
||||
|
||||
/*
|
||||
* If a backend dies in an ugly way (i.e. exit status not 0) then we
|
||||
@ -2188,7 +2188,7 @@ CleanupBackend(int pid,
|
||||
*/
|
||||
if (exitstatus != 0)
|
||||
{
|
||||
HandleChildCrash(pid, exitstatus, gettext("server process"));
|
||||
HandleChildCrash(pid, exitstatus, _("server process"));
|
||||
return;
|
||||
}
|
||||
|
||||
@ -2512,7 +2512,7 @@ report_fork_failure_to_client(Port *port, int errnum)
|
||||
|
||||
/* Format the error message packet (always V2 protocol) */
|
||||
snprintf(buffer, sizeof(buffer), "E%s%s\n",
|
||||
gettext("could not fork new process for connection: "),
|
||||
_("could not fork new process for connection: "),
|
||||
strerror(errnum));
|
||||
|
||||
/* Set port to non-blocking. Don't do send() if this fails */
|
||||
|
@ -12,7 +12,7 @@
|
||||
*
|
||||
*
|
||||
* IDENTIFICATION
|
||||
* $PostgreSQL: pgsql/src/backend/storage/lmgr/deadlock.c,v 1.32 2004/12/31 22:01:05 pgsql Exp $
|
||||
* $PostgreSQL: pgsql/src/backend/storage/lmgr/deadlock.c,v 1.33 2005/02/22 04:36:49 momjian Exp $
|
||||
*
|
||||
* Interface:
|
||||
*
|
||||
@ -864,7 +864,7 @@ DeadLockReport(void)
|
||||
{
|
||||
/* Lock is for transaction ID */
|
||||
appendStringInfo(&buf,
|
||||
gettext("Process %d waits for %s on transaction %u; blocked by process %d."),
|
||||
_("Process %d waits for %s on transaction %u; blocked by process %d."),
|
||||
info->pid,
|
||||
GetLockmodeName(info->lockmode),
|
||||
info->locktag.objId.xid,
|
||||
@ -874,7 +874,7 @@ DeadLockReport(void)
|
||||
{
|
||||
/* Lock is for a relation */
|
||||
appendStringInfo(&buf,
|
||||
gettext("Process %d waits for %s on relation %u of database %u; blocked by process %d."),
|
||||
_("Process %d waits for %s on relation %u of database %u; blocked by process %d."),
|
||||
info->pid,
|
||||
GetLockmodeName(info->lockmode),
|
||||
info->locktag.relId,
|
||||
|
@ -8,7 +8,7 @@
|
||||
*
|
||||
*
|
||||
* IDENTIFICATION
|
||||
* $PostgreSQL: pgsql/src/backend/tcop/postgres.c,v 1.441 2005/02/20 02:21:57 tgl Exp $
|
||||
* $PostgreSQL: pgsql/src/backend/tcop/postgres.c,v 1.442 2005/02/22 04:37:17 momjian Exp $
|
||||
*
|
||||
* NOTES
|
||||
* this is the "main" module of the postgres backend and
|
||||
@ -2120,35 +2120,35 @@ assign_max_stack_depth(int newval, bool doit, GucSource source)
|
||||
static void
|
||||
usage(const char *progname)
|
||||
{
|
||||
printf(gettext("%s is the PostgreSQL stand-alone backend. It is not\nintended to be used by normal users.\n\n"), progname);
|
||||
printf(_("%s is the PostgreSQL stand-alone backend. It is not\nintended to be used by normal users.\n\n"), progname);
|
||||
|
||||
printf(gettext("Usage:\n %s [OPTION]... [DBNAME]\n\n"), progname);
|
||||
printf(gettext("Options:\n"));
|
||||
printf(_("Usage:\n %s [OPTION]... [DBNAME]\n\n"), progname);
|
||||
printf(_("Options:\n"));
|
||||
#ifdef USE_ASSERT_CHECKING
|
||||
printf(gettext(" -A 1|0 enable/disable run-time assert checking\n"));
|
||||
printf(_(" -A 1|0 enable/disable run-time assert checking\n"));
|
||||
#endif
|
||||
printf(gettext(" -B NBUFFERS number of shared buffers\n"));
|
||||
printf(gettext(" -c NAME=VALUE set run-time parameter\n"));
|
||||
printf(gettext(" -d 0-5 debugging level (0 is off)\n"));
|
||||
printf(gettext(" -D DATADIR database directory\n"));
|
||||
printf(gettext(" -e use European date input format (DMY)\n"));
|
||||
printf(gettext(" -E echo query before execution\n"));
|
||||
printf(gettext(" -F turn fsync off\n"));
|
||||
printf(gettext(" -N do not use newline as interactive query delimiter\n"));
|
||||
printf(gettext(" -o FILENAME send stdout and stderr to given file\n"));
|
||||
printf(gettext(" -P disable system indexes\n"));
|
||||
printf(gettext(" -s show statistics after each query\n"));
|
||||
printf(gettext(" -S WORK-MEM set amount of memory for sorts (in kB)\n"));
|
||||
printf(gettext(" --describe-config describe configuration parameters, then exit\n"));
|
||||
printf(gettext(" --help show this help, then exit\n"));
|
||||
printf(gettext(" --version output version information, then exit\n"));
|
||||
printf(gettext("\nDeveloper options:\n"));
|
||||
printf(gettext(" -f s|i|n|m|h forbid use of some plan types\n"));
|
||||
printf(gettext(" -i do not execute queries\n"));
|
||||
printf(gettext(" -O allow system table structure changes\n"));
|
||||
printf(gettext(" -t pa|pl|ex show timings after each query\n"));
|
||||
printf(gettext(" -W NUM wait NUM seconds to allow attach from a debugger\n"));
|
||||
printf(gettext("\nReport bugs to <pgsql-bugs@postgresql.org>.\n"));
|
||||
printf(_(" -B NBUFFERS number of shared buffers\n"));
|
||||
printf(_(" -c NAME=VALUE set run-time parameter\n"));
|
||||
printf(_(" -d 0-5 debugging level (0 is off)\n"));
|
||||
printf(_(" -D DATADIR database directory\n"));
|
||||
printf(_(" -e use European date input format (DMY)\n"));
|
||||
printf(_(" -E echo query before execution\n"));
|
||||
printf(_(" -F turn fsync off\n"));
|
||||
printf(_(" -N do not use newline as interactive query delimiter\n"));
|
||||
printf(_(" -o FILENAME send stdout and stderr to given file\n"));
|
||||
printf(_(" -P disable system indexes\n"));
|
||||
printf(_(" -s show statistics after each query\n"));
|
||||
printf(_(" -S WORK-MEM set amount of memory for sorts (in kB)\n"));
|
||||
printf(_(" --describe-config describe configuration parameters, then exit\n"));
|
||||
printf(_(" --help show this help, then exit\n"));
|
||||
printf(_(" --version output version information, then exit\n"));
|
||||
printf(_("\nDeveloper options:\n"));
|
||||
printf(_(" -f s|i|n|m|h forbid use of some plan types\n"));
|
||||
printf(_(" -i do not execute queries\n"));
|
||||
printf(_(" -O allow system table structure changes\n"));
|
||||
printf(_(" -t pa|pl|ex show timings after each query\n"));
|
||||
printf(_(" -W NUM wait NUM seconds to allow attach from a debugger\n"));
|
||||
printf(_("\nReport bugs to <pgsql-bugs@postgresql.org>.\n"));
|
||||
}
|
||||
|
||||
|
||||
|
@ -42,7 +42,7 @@
|
||||
*
|
||||
*
|
||||
* IDENTIFICATION
|
||||
* $PostgreSQL: pgsql/src/backend/utils/error/elog.c,v 1.155 2004/12/31 22:01:27 pgsql Exp $
|
||||
* $PostgreSQL: pgsql/src/backend/utils/error/elog.c,v 1.156 2005/02/22 04:37:38 momjian Exp $
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
@ -598,7 +598,7 @@ errcode_for_socket_access(void)
|
||||
char *fmtbuf; \
|
||||
StringInfoData buf; \
|
||||
/* Internationalize the error format string */ \
|
||||
fmt = gettext(fmt); \
|
||||
fmt = _(fmt); \
|
||||
/* Expand %m in format string */ \
|
||||
fmtbuf = expand_fmt_string(fmt, edata); \
|
||||
initStringInfo(&buf); \
|
||||
@ -1347,7 +1347,7 @@ log_line_prefix(StringInfo buf)
|
||||
const char *username = MyProcPort->user_name;
|
||||
|
||||
if (username == NULL || *username == '\0')
|
||||
username = gettext("[unknown]");
|
||||
username = _("[unknown]");
|
||||
appendStringInfo(buf, "%s", username);
|
||||
}
|
||||
break;
|
||||
@ -1357,7 +1357,7 @@ log_line_prefix(StringInfo buf)
|
||||
const char *dbname = MyProcPort->database_name;
|
||||
|
||||
if (dbname == NULL || *dbname == '\0')
|
||||
dbname = gettext("[unknown]");
|
||||
dbname = _("[unknown]");
|
||||
appendStringInfo(buf, "%s", dbname);
|
||||
}
|
||||
break;
|
||||
@ -1485,13 +1485,13 @@ send_message_to_server_log(ErrorData *edata)
|
||||
if (edata->message)
|
||||
append_with_tabs(&buf, edata->message);
|
||||
else
|
||||
append_with_tabs(&buf, gettext("missing error text"));
|
||||
append_with_tabs(&buf, _("missing error text"));
|
||||
|
||||
if (edata->cursorpos > 0)
|
||||
appendStringInfo(&buf, gettext(" at character %d"),
|
||||
appendStringInfo(&buf, _(" at character %d"),
|
||||
edata->cursorpos);
|
||||
else if (edata->internalpos > 0)
|
||||
appendStringInfo(&buf, gettext(" at character %d"),
|
||||
appendStringInfo(&buf, _(" at character %d"),
|
||||
edata->internalpos);
|
||||
|
||||
appendStringInfoChar(&buf, '\n');
|
||||
@ -1501,28 +1501,28 @@ send_message_to_server_log(ErrorData *edata)
|
||||
if (edata->detail)
|
||||
{
|
||||
log_line_prefix(&buf);
|
||||
appendStringInfoString(&buf, gettext("DETAIL: "));
|
||||
appendStringInfoString(&buf, _("DETAIL: "));
|
||||
append_with_tabs(&buf, edata->detail);
|
||||
appendStringInfoChar(&buf, '\n');
|
||||
}
|
||||
if (edata->hint)
|
||||
{
|
||||
log_line_prefix(&buf);
|
||||
appendStringInfoString(&buf, gettext("HINT: "));
|
||||
appendStringInfoString(&buf, _("HINT: "));
|
||||
append_with_tabs(&buf, edata->hint);
|
||||
appendStringInfoChar(&buf, '\n');
|
||||
}
|
||||
if (edata->internalquery)
|
||||
{
|
||||
log_line_prefix(&buf);
|
||||
appendStringInfoString(&buf, gettext("QUERY: "));
|
||||
appendStringInfoString(&buf, _("QUERY: "));
|
||||
append_with_tabs(&buf, edata->internalquery);
|
||||
appendStringInfoChar(&buf, '\n');
|
||||
}
|
||||
if (edata->context)
|
||||
{
|
||||
log_line_prefix(&buf);
|
||||
appendStringInfoString(&buf, gettext("CONTEXT: "));
|
||||
appendStringInfoString(&buf, _("CONTEXT: "));
|
||||
append_with_tabs(&buf, edata->context);
|
||||
appendStringInfoChar(&buf, '\n');
|
||||
}
|
||||
@ -1532,14 +1532,14 @@ send_message_to_server_log(ErrorData *edata)
|
||||
if (edata->funcname && edata->filename)
|
||||
{
|
||||
log_line_prefix(&buf);
|
||||
appendStringInfo(&buf, gettext("LOCATION: %s, %s:%d\n"),
|
||||
appendStringInfo(&buf, _("LOCATION: %s, %s:%d\n"),
|
||||
edata->funcname, edata->filename,
|
||||
edata->lineno);
|
||||
}
|
||||
else if (edata->filename)
|
||||
{
|
||||
log_line_prefix(&buf);
|
||||
appendStringInfo(&buf, gettext("LOCATION: %s:%d\n"),
|
||||
appendStringInfo(&buf, _("LOCATION: %s:%d\n"),
|
||||
edata->filename, edata->lineno);
|
||||
}
|
||||
}
|
||||
@ -1552,7 +1552,7 @@ send_message_to_server_log(ErrorData *edata)
|
||||
if (edata->elevel >= log_min_error_statement && debug_query_string != NULL)
|
||||
{
|
||||
log_line_prefix(&buf);
|
||||
appendStringInfoString(&buf, gettext("STATEMENT: "));
|
||||
appendStringInfoString(&buf, _("STATEMENT: "));
|
||||
append_with_tabs(&buf, debug_query_string);
|
||||
appendStringInfoChar(&buf, '\n');
|
||||
}
|
||||
@ -1678,7 +1678,7 @@ send_message_to_frontend(ErrorData *edata)
|
||||
if (edata->message)
|
||||
pq_sendstring(&msgbuf, edata->message);
|
||||
else
|
||||
pq_sendstring(&msgbuf, gettext("missing error text"));
|
||||
pq_sendstring(&msgbuf, _("missing error text"));
|
||||
|
||||
if (edata->detail)
|
||||
{
|
||||
@ -1754,13 +1754,13 @@ send_message_to_frontend(ErrorData *edata)
|
||||
if (edata->message)
|
||||
appendStringInfoString(&buf, edata->message);
|
||||
else
|
||||
appendStringInfoString(&buf, gettext("missing error text"));
|
||||
appendStringInfoString(&buf, _("missing error text"));
|
||||
|
||||
if (edata->cursorpos > 0)
|
||||
appendStringInfo(&buf, gettext(" at character %d"),
|
||||
appendStringInfo(&buf, _(" at character %d"),
|
||||
edata->cursorpos);
|
||||
else if (edata->internalpos > 0)
|
||||
appendStringInfo(&buf, gettext(" at character %d"),
|
||||
appendStringInfo(&buf, _(" at character %d"),
|
||||
edata->internalpos);
|
||||
|
||||
appendStringInfoChar(&buf, '\n');
|
||||
@ -1870,7 +1870,7 @@ useful_strerror(int errnum)
|
||||
* expanded.
|
||||
*/
|
||||
snprintf(errorstr_buf, sizeof(errorstr_buf),
|
||||
gettext("operating system error %d"), errnum);
|
||||
_("operating system error %d"), errnum);
|
||||
str = errorstr_buf;
|
||||
}
|
||||
|
||||
@ -1893,29 +1893,29 @@ error_severity(int elevel)
|
||||
case DEBUG3:
|
||||
case DEBUG4:
|
||||
case DEBUG5:
|
||||
prefix = gettext("DEBUG");
|
||||
prefix = _("DEBUG");
|
||||
break;
|
||||
case LOG:
|
||||
case COMMERROR:
|
||||
prefix = gettext("LOG");
|
||||
prefix = _("LOG");
|
||||
break;
|
||||
case INFO:
|
||||
prefix = gettext("INFO");
|
||||
prefix = _("INFO");
|
||||
break;
|
||||
case NOTICE:
|
||||
prefix = gettext("NOTICE");
|
||||
prefix = _("NOTICE");
|
||||
break;
|
||||
case WARNING:
|
||||
prefix = gettext("WARNING");
|
||||
prefix = _("WARNING");
|
||||
break;
|
||||
case ERROR:
|
||||
prefix = gettext("ERROR");
|
||||
prefix = _("ERROR");
|
||||
break;
|
||||
case FATAL:
|
||||
prefix = gettext("FATAL");
|
||||
prefix = _("FATAL");
|
||||
break;
|
||||
case PANIC:
|
||||
prefix = gettext("PANIC");
|
||||
prefix = _("PANIC");
|
||||
break;
|
||||
default:
|
||||
prefix = "???";
|
||||
@ -1956,7 +1956,7 @@ write_stderr(const char *fmt,...)
|
||||
{
|
||||
va_list ap;
|
||||
|
||||
fmt = gettext(fmt);
|
||||
fmt = _(fmt);
|
||||
|
||||
va_start(ap, fmt);
|
||||
#ifndef WIN32
|
||||
|
@ -10,7 +10,7 @@
|
||||
* Portions Copyright (c) 1996-2005, PostgreSQL Global Development Group
|
||||
*
|
||||
* IDENTIFICATION
|
||||
* $PostgreSQL: pgsql/src/backend/utils/misc/help_config.c,v 1.14 2004/12/31 22:02:45 pgsql Exp $
|
||||
* $PostgreSQL: pgsql/src/backend/utils/misc/help_config.c,v 1.15 2005/02/22 04:38:05 momjian Exp $
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
@ -91,7 +91,7 @@ printMixedStruct(mixedStruct *structToPrint)
|
||||
printf("%s\t%s\t%s\t",
|
||||
structToPrint->generic.name,
|
||||
GucContext_Names[structToPrint->generic.context],
|
||||
gettext(config_group_names[structToPrint->generic.group]));
|
||||
_(config_group_names[structToPrint->generic.group]));
|
||||
|
||||
switch (structToPrint->generic.vartype)
|
||||
{
|
||||
@ -127,6 +127,6 @@ printMixedStruct(mixedStruct *structToPrint)
|
||||
}
|
||||
|
||||
printf("%s\t%s\n",
|
||||
(structToPrint->generic.short_desc == NULL) ? "" : gettext(structToPrint->generic.short_desc),
|
||||
(structToPrint->generic.long_desc == NULL) ? "" : gettext(structToPrint->generic.long_desc));
|
||||
(structToPrint->generic.short_desc == NULL) ? "" : _(structToPrint->generic.short_desc),
|
||||
(structToPrint->generic.long_desc == NULL) ? "" : _(structToPrint->generic.long_desc));
|
||||
}
|
||||
|
Reference in New Issue
Block a user