Skip to content

Commit 8561203

Browse files
committed
Message style improvements
1 parent 7431cb2 commit 8561203

File tree

2 files changed

+9
-8
lines changed

2 files changed

+9
-8
lines changed

contrib/pg_archivecleanup/pg_archivecleanup.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,7 @@ Initialize(void)
8383
if (stat(archiveLocation, &stat_buf) != 0 ||
8484
!S_ISDIR(stat_buf.st_mode))
8585
{
86-
fprintf(stderr, "%s: archiveLocation \"%s\" does not exist\n",
86+
fprintf(stderr, "%s: archive location \"%s\" does not exist\n",
8787
progname, archiveLocation);
8888
exit(2);
8989
}
@@ -135,7 +135,7 @@ CleanupPriorWALFiles(void)
135135
closedir(xldir);
136136
}
137137
else
138-
fprintf(stderr, "%s: could not open archiveLocation \"%s\": %s\n",
138+
fprintf(stderr, "%s: could not open archive location \"%s\": %s\n",
139139
progname, archiveLocation, strerror(errno));
140140
}
141141

contrib/pg_standby/pg_standby.c

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -173,7 +173,7 @@ CustomizableInitialize(void)
173173
*/
174174
if (stat(archiveLocation, &stat_buf) != 0)
175175
{
176-
fprintf(stderr, "%s: archiveLocation \"%s\" does not exist\n", progname, archiveLocation);
176+
fprintf(stderr, "%s: archive location \"%s\" does not exist\n", progname, archiveLocation);
177177
fflush(stderr);
178178
exit(2);
179179
}
@@ -283,12 +283,12 @@ CustomizableCleanupPriorWALFiles(void)
283283
#endif
284284

285285
if (debug)
286-
fprintf(stderr, "\nremoving \"%s\"", WALFilePath);
286+
fprintf(stderr, "\nremoving file \"%s\"", WALFilePath);
287287

288288
rc = unlink(WALFilePath);
289289
if (rc != 0)
290290
{
291-
fprintf(stderr, "\n%s: ERROR failed to remove \"%s\": %s",
291+
fprintf(stderr, "\n%s: ERROR: could not remove file \"%s\": %s\n",
292292
progname, WALFilePath, strerror(errno));
293293
break;
294294
}
@@ -298,7 +298,8 @@ CustomizableCleanupPriorWALFiles(void)
298298
fprintf(stderr, "\n");
299299
}
300300
else
301-
fprintf(stderr, "%s: archiveLocation \"%s\" open error\n", progname, archiveLocation);
301+
fprintf(stderr, "%s: could not open archive location \"%s\": %s\n",
302+
progname, archiveLocation, strerror(errno));
302303

303304
closedir(xldir);
304305
fflush(stderr);
@@ -693,7 +694,7 @@ main(int argc, char **argv)
693694
}
694695
else
695696
{
696-
fprintf(stderr, "%s: use %%f to specify nextWALFileName\n", progname);
697+
fprintf(stderr, "%s: must specify WAL file name as second non-option argument (use \"%%f\")\n", progname);
697698
fprintf(stderr, "Try \"%s --help\" for more information.\n", progname);
698699
exit(2);
699700
}
@@ -705,7 +706,7 @@ main(int argc, char **argv)
705706
}
706707
else
707708
{
708-
fprintf(stderr, "%s: use %%p to specify xlogFilePath\n", progname);
709+
fprintf(stderr, "%s: must specify xlog destination as third non-option argument (use \"%%p\")\n", progname);
709710
fprintf(stderr, "Try \"%s --help\" for more information.\n", progname);
710711
exit(2);
711712
}

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