Commit b642e50a authored by Tom Lane's avatar Tom Lane

Fix backwards test for Windows service-ness in pg_ctl.

A thinko in a9676139 caused pg_ctl to get it exactly backwards when
deciding whether to report problems to the Windows eventlog or to stderr.
Per bug #14001 from Manuel Mathar, who also identified the fix.
Like the previous patch, back-patch to all supported branches.
parent 94f1adcc
...@@ -210,7 +210,7 @@ write_stderr(const char *fmt,...) ...@@ -210,7 +210,7 @@ write_stderr(const char *fmt,...)
* On Win32, we print to stderr if running on a console, or write to * On Win32, we print to stderr if running on a console, or write to
* eventlog if running as a service * eventlog if running as a service
*/ */
if (!pgwin32_is_service()) /* Running as a service */ if (pgwin32_is_service()) /* Running as a service */
{ {
char errbuf[2048]; /* Arbitrary size? */ char errbuf[2048]; /* Arbitrary size? */
......
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