Skip to content

Commit 7ce9b36

Browse files
committed
Make some messages more consistent
1 parent 54af876 commit 7ce9b36

File tree

10 files changed

+26
-26
lines changed

10 files changed

+26
-26
lines changed

contrib/pg_standby/pg_standby.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -270,7 +270,7 @@ CustomizableCleanupPriorWALFiles(void)
270270

271271
rc = unlink(WALFilePath);
272272
if (rc !=0 )
273-
fprintf(stderr, "\npg_standby: ERROR failed to remove \"%s\" because %s\n", WALFilePath, strerror(errno));
273+
fprintf(stderr, "\npg_standby: ERROR failed to remove \"%s\": %s\n", WALFilePath, strerror(errno));
274274

275275

276276
}
@@ -320,7 +320,7 @@ CheckForExternalTrigger(void)
320320
rc = unlink(triggerPath);
321321
if (rc != 0)
322322
{
323-
fprintf(stderr, "\n ERROR: unable to remove \"%s\", because %s", triggerPath, strerror(errno));
323+
fprintf(stderr, "\n ERROR: could not remove \"%s\": %s", triggerPath, strerror(errno));
324324
fflush(stderr);
325325
exit(rc);
326326
}

src/backend/access/transam/xlog.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
* Portions Copyright (c) 1996-2007, PostgreSQL Global Development Group
88
* Portions Copyright (c) 1994, Regents of the University of California
99
*
10-
* $PostgreSQL: pgsql/src/backend/access/transam/xlog.c,v 1.271 2007/05/31 07:36:12 petere Exp $
10+
* $PostgreSQL: pgsql/src/backend/access/transam/xlog.c,v 1.272 2007/05/31 15:13:01 petere Exp $
1111
*
1212
*-------------------------------------------------------------------------
1313
*/
@@ -2933,7 +2933,7 @@ ReadRecord(XLogRecPtr *RecPtr, int emode)
29332933
{
29342934
ereport(emode,
29352935
(errcode_for_file_access(),
2936-
errmsg("could not read from log file %u, segment %u at offset %u: %m",
2936+
errmsg("could not read from log file %u, segment %u, offset %u: %m",
29372937
readId, readSeg, readOff)));
29382938
goto next_record_is_invalid;
29392939
}

src/backend/commands/tablespace.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@
3737
*
3838
*
3939
* IDENTIFICATION
40-
* $PostgreSQL: pgsql/src/backend/commands/tablespace.c,v 1.45 2007/03/22 19:51:44 tgl Exp $
40+
* $PostgreSQL: pgsql/src/backend/commands/tablespace.c,v 1.46 2007/05/31 15:13:02 petere Exp $
4141
*
4242
*-------------------------------------------------------------------------
4343
*/
@@ -570,7 +570,7 @@ remove_tablespace_directories(Oid tablespaceoid, bool redo)
570570
if (rmdir(subfile) < 0)
571571
ereport(ERROR,
572572
(errcode_for_file_access(),
573-
errmsg("could not delete directory \"%s\": %m",
573+
errmsg("could not remove directory \"%s\": %m",
574574
subfile)));
575575

576576
pfree(subfile);

src/bin/initdb/initdb.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@
4242
* Portions Copyright (c) 1994, Regents of the University of California
4343
* Portions taken from FreeBSD.
4444
*
45-
* $PostgreSQL: pgsql/src/bin/initdb/initdb.c,v 1.136 2007/03/29 22:46:42 momjian Exp $
45+
* $PostgreSQL: pgsql/src/bin/initdb/initdb.c,v 1.137 2007/05/31 15:13:03 petere Exp $
4646
*
4747
*-------------------------------------------------------------------------
4848
*/
@@ -2328,7 +2328,7 @@ CreateRestrictedProcess(char *cmd, PROCESS_INFORMATION * processInfo)
23282328

23292329
if (_CreateRestrictedToken == NULL)
23302330
{
2331-
fprintf(stderr, "WARNING: Unable to create restricted tokens on this platform\n");
2331+
fprintf(stderr, "WARNING: cannot create restricted tokens on this platform\n");
23322332
if (Advapi32Handle != NULL)
23332333
FreeLibrary(Advapi32Handle);
23342334
return 0;
@@ -3005,7 +3005,7 @@ main(int argc, char *argv[])
30053005
exit_nicely();
30063006
}
30073007
#else
3008-
fprintf(stderr, _("%s: symlinks are not supported on this plataform"));
3008+
fprintf(stderr, _("%s: symlinks are not supported on this platform"));
30093009
exit_nicely();
30103010
#endif
30113011
}

src/bin/pg_config/pg_config.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
*
1818
* Portions Copyright (c) 1996-2007, PostgreSQL Global Development Group
1919
*
20-
* $PostgreSQL: pgsql/src/bin/pg_config/pg_config.c,v 1.24 2007/02/07 00:28:54 petere Exp $
20+
* $PostgreSQL: pgsql/src/bin/pg_config/pg_config.c,v 1.25 2007/05/31 15:13:04 petere Exp $
2121
*
2222
*-------------------------------------------------------------------------
2323
*/
@@ -469,7 +469,7 @@ main(int argc, char **argv)
469469

470470
if (ret)
471471
{
472-
fprintf(stderr, _("%s: could not find own executable\n"), progname);
472+
fprintf(stderr, _("%s: could not find own program executable\n"), progname);
473473
exit(1);
474474
}
475475

src/bin/pg_ctl/pg_ctl.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
*
55
* Portions Copyright (c) 1996-2007, PostgreSQL Global Development Group
66
*
7-
* $PostgreSQL: pgsql/src/bin/pg_ctl/pg_ctl.c,v 1.79 2007/03/18 16:50:44 neilc Exp $
7+
* $PostgreSQL: pgsql/src/bin/pg_ctl/pg_ctl.c,v 1.80 2007/05/31 15:13:04 petere Exp $
88
*
99
*-------------------------------------------------------------------------
1010
*/
@@ -1257,7 +1257,7 @@ CreateRestrictedProcess(char *cmd, PROCESS_INFORMATION * processInfo)
12571257
* NT4 doesn't have CreateRestrictedToken, so just call ordinary
12581258
* CreateProcess
12591259
*/
1260-
write_stderr("WARNING: Unable to create restricted tokens on this platform\n");
1260+
write_stderr("WARNING: cannot create restricted tokens on this platform\n");
12611261
if (Advapi32Handle != NULL)
12621262
FreeLibrary(Advapi32Handle);
12631263
return CreateProcess(NULL, cmd, NULL, NULL, FALSE, 0, NULL, NULL, &si, processInfo);
@@ -1332,7 +1332,7 @@ CreateRestrictedProcess(char *cmd, PROCESS_INFORMATION * processInfo)
13321332
* Log error if we can't get version, or if we're on WinXP/2003 or
13331333
* newer
13341334
*/
1335-
write_stderr("WARNING: Unable to locate all job object functions in system API!\n");
1335+
write_stderr("WARNING: could not locate all job object functions in system API\n");
13361336
}
13371337
else
13381338
{

src/interfaces/ecpg/ecpglib/error.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
/* $PostgreSQL: pgsql/src/interfaces/ecpg/ecpglib/error.c,v 1.15 2006/10/04 00:30:11 momjian Exp $ */
1+
/* $PostgreSQL: pgsql/src/interfaces/ecpg/ecpglib/error.c,v 1.16 2007/05/31 15:13:05 petere Exp $ */
22

33
#define POSTGRES_ECPG_INTERNAL
44
#include "postgres_fe.h"
@@ -62,7 +62,7 @@ ECPGraise(int line, int code, const char *sqlstate, const char *str)
6262

6363
case ECPG_CONVERT_BOOL:
6464
snprintf(sqlca->sqlerrm.sqlerrmc, sizeof(sqlca->sqlerrm.sqlerrmc),
65-
"Unable to convert %s to bool on line %d.", str, line);
65+
"Could not convert %s to bool on line %d.", str, line);
6666
break;
6767

6868
case ECPG_EMPTY:

src/pl/plpython/plpython.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
/**********************************************************************
22
* plpython.c - python as a procedural language for PostgreSQL
33
*
4-
* $PostgreSQL: pgsql/src/pl/plpython/plpython.c,v 1.100 2007/04/04 17:28:11 momjian Exp $
4+
* $PostgreSQL: pgsql/src/pl/plpython/plpython.c,v 1.101 2007/05/31 15:13:05 petere Exp $
55
*
66
*********************************************************************
77
*/
@@ -484,7 +484,7 @@ PLy_modify_tuple(PLyProcedure * proc, PyObject * pltd, TriggerData *tdata,
484484
PG_TRY();
485485
{
486486
if ((plntup = PyDict_GetItemString(pltd, "new")) == NULL)
487-
elog(ERROR, "TD[\"new\"] deleted, unable to modify tuple");
487+
elog(ERROR, "TD[\"new\"] deleted, cannot modify tuple");
488488
if (!PyDict_Check(plntup))
489489
elog(ERROR, "TD[\"new\"] is not a dictionary object");
490490
Py_INCREF(plntup);
@@ -2822,7 +2822,7 @@ PLy_output(volatile int level, PyObject * self, PyObject * args)
28222822
if (so == NULL || ((sv = PyString_AsString(so)) == NULL))
28232823
{
28242824
level = ERROR;
2825-
sv = "Unable to parse error message in `plpy.elog'";
2825+
sv = "could not parse error message in `plpy.elog'";
28262826
}
28272827

28282828
oldcontext = CurrentMemoryContext;

src/test/regress/pg_regress.c

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
* Portions Copyright (c) 1996-2007, PostgreSQL Global Development Group
1212
* Portions Copyright (c) 1994, Regents of the University of California
1313
*
14-
* $PostgreSQL: pgsql/src/test/regress/pg_regress.c,v 1.31 2007/02/08 19:48:28 tgl Exp $
14+
* $PostgreSQL: pgsql/src/test/regress/pg_regress.c,v 1.32 2007/05/31 15:13:06 petere Exp $
1515
*
1616
*-------------------------------------------------------------------------
1717
*/
@@ -886,14 +886,14 @@ spawn_process(const char *cmdline)
886886
{
887887
if (Advapi32Handle != NULL)
888888
FreeLibrary(Advapi32Handle);
889-
fprintf(stderr, "ERROR: Unable to create restricted tokens on this platform\n");
889+
fprintf(stderr, "ERROR: cannot create restricted tokens on this platform\n");
890890
exit_nicely(2);
891891
}
892892

893893
/* Open the current token to use as base for the restricted one */
894894
if (!OpenProcessToken(GetCurrentProcess(), TOKEN_ALL_ACCESS, &origToken))
895895
{
896-
fprintf(stderr, "Failed to open process token: %lu\n", GetLastError());
896+
fprintf(stderr, "could not open process token: %lu\n", GetLastError());
897897
exit_nicely(2);
898898
}
899899

@@ -904,7 +904,7 @@ spawn_process(const char *cmdline)
904904
!AllocateAndInitializeSid(&NtAuthority, 2,
905905
SECURITY_BUILTIN_DOMAIN_RID, DOMAIN_ALIAS_RID_POWER_USERS, 0, 0, 0, 0, 0, 0, &dropSids[1].Sid))
906906
{
907-
fprintf(stderr, "Failed to allocate SIDs: %lu\n", GetLastError());
907+
fprintf(stderr, "could not allocate SIDs: %lu\n", GetLastError());
908908
exit_nicely(2);
909909
}
910910

@@ -923,7 +923,7 @@ spawn_process(const char *cmdline)
923923

924924
if (!b)
925925
{
926-
fprintf(stderr, "Failed to create restricted token: %lu\n", GetLastError());
926+
fprintf(stderr, "could not create restricted token: %lu\n", GetLastError());
927927
exit_nicely(2);
928928
}
929929

src/timezone/pgtz.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
* Portions Copyright (c) 1996-2007, PostgreSQL Global Development Group
77
*
88
* IDENTIFICATION
9-
* $PostgreSQL: pgsql/src/timezone/pgtz.c,v 1.50 2007/02/10 14:58:55 petere Exp $
9+
* $PostgreSQL: pgsql/src/timezone/pgtz.c,v 1.51 2007/05/31 15:13:06 petere Exp $
1010
*
1111
*-------------------------------------------------------------------------
1212
*/
@@ -455,7 +455,7 @@ identify_system_timezone(void)
455455
if (std_zone_name[0] == '\0')
456456
{
457457
ereport(LOG,
458-
(errmsg("unable to determine system timezone, defaulting to \"%s\"", "GMT"),
458+
(errmsg("could not determine system time zone, defaulting to \"%s\"", "GMT"),
459459
errhint("You can specify the correct timezone in postgresql.conf.")));
460460
return NULL; /* go to GMT */
461461
}

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy