Commit 2005b77b authored by Peter Eisentraut's avatar Peter Eisentraut

initdb: Mark more messages for translation

Some Windows-only messages had apparently been forgotten so far.

Also make the wording of the messages more consistent with similar
messages other parts, such as pg_ctl and pg_regress.
parent 68219aaf
...@@ -2431,7 +2431,7 @@ CreateRestrictedProcess(char *cmd, PROCESS_INFORMATION *processInfo) ...@@ -2431,7 +2431,7 @@ CreateRestrictedProcess(char *cmd, PROCESS_INFORMATION *processInfo)
if (_CreateRestrictedToken == NULL) if (_CreateRestrictedToken == NULL)
{ {
fprintf(stderr, "WARNING: cannot create restricted tokens on this platform\n"); fprintf(stderr, _("%s: WARNING: cannot create restricted tokens on this platform\n"), progname);
if (Advapi32Handle != NULL) if (Advapi32Handle != NULL)
FreeLibrary(Advapi32Handle); FreeLibrary(Advapi32Handle);
return 0; return 0;
...@@ -2440,7 +2440,7 @@ CreateRestrictedProcess(char *cmd, PROCESS_INFORMATION *processInfo) ...@@ -2440,7 +2440,7 @@ CreateRestrictedProcess(char *cmd, PROCESS_INFORMATION *processInfo)
/* Open the current token to use as a base for the restricted one */ /* Open the current token to use as a base for the restricted one */
if (!OpenProcessToken(GetCurrentProcess(), TOKEN_ALL_ACCESS, &origToken)) if (!OpenProcessToken(GetCurrentProcess(), TOKEN_ALL_ACCESS, &origToken))
{ {
fprintf(stderr, "Failed to open process token: error code %lu\n", GetLastError()); fprintf(stderr, _("%s: could not open process token: error code %lu\n"), progname, GetLastError());
return 0; return 0;
} }
...@@ -2453,7 +2453,7 @@ CreateRestrictedProcess(char *cmd, PROCESS_INFORMATION *processInfo) ...@@ -2453,7 +2453,7 @@ CreateRestrictedProcess(char *cmd, PROCESS_INFORMATION *processInfo)
SECURITY_BUILTIN_DOMAIN_RID, DOMAIN_ALIAS_RID_POWER_USERS, 0, 0, 0, 0, 0, SECURITY_BUILTIN_DOMAIN_RID, DOMAIN_ALIAS_RID_POWER_USERS, 0, 0, 0, 0, 0,
0, &dropSids[1].Sid)) 0, &dropSids[1].Sid))
{ {
fprintf(stderr, "Failed to allocate SIDs: error code %lu\n", GetLastError()); fprintf(stderr, _("%s: could not to allocate SIDs: error code %lu\n"), progname, GetLastError());
return 0; return 0;
} }
...@@ -2472,7 +2472,7 @@ CreateRestrictedProcess(char *cmd, PROCESS_INFORMATION *processInfo) ...@@ -2472,7 +2472,7 @@ CreateRestrictedProcess(char *cmd, PROCESS_INFORMATION *processInfo)
if (!b) if (!b)
{ {
fprintf(stderr, "Failed to create restricted token: error code %lu\n", GetLastError()); fprintf(stderr, _("%s: could not create restricted token: error code %lu\n"), progname, GetLastError());
return 0; return 0;
} }
...@@ -2493,7 +2493,7 @@ CreateRestrictedProcess(char *cmd, PROCESS_INFORMATION *processInfo) ...@@ -2493,7 +2493,7 @@ CreateRestrictedProcess(char *cmd, PROCESS_INFORMATION *processInfo)
processInfo)) processInfo))
{ {
fprintf(stderr, "CreateProcessAsUser failed: error code %lu\n", GetLastError()); fprintf(stderr, _("%s: could not start process for \"%s\": error code %lu\n"), progname, cmd, GetLastError());
return 0; return 0;
} }
...@@ -2835,7 +2835,7 @@ main(int argc, char *argv[]) ...@@ -2835,7 +2835,7 @@ main(int argc, char *argv[])
if (!CreateRestrictedProcess(cmdline, &pi)) if (!CreateRestrictedProcess(cmdline, &pi))
{ {
fprintf(stderr, "Failed to re-exec with restricted token: error code %lu\n", GetLastError()); fprintf(stderr, _("%s: could not re-exec with restricted token: error code %lu\n"), progname, GetLastError());
} }
else else
{ {
...@@ -2850,7 +2850,7 @@ main(int argc, char *argv[]) ...@@ -2850,7 +2850,7 @@ main(int argc, char *argv[])
if (!GetExitCodeProcess(pi.hProcess, &x)) if (!GetExitCodeProcess(pi.hProcess, &x))
{ {
fprintf(stderr, "Failed to get exit code from subprocess: error code %lu\n", GetLastError()); fprintf(stderr, _("%s: could not get exit code from subprocess: error code %lu\n"), progname, GetLastError());
exit(1); exit(1);
} }
exit(x); exit(x);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment