Re: [PATCH] Fix incorrect fprintf usage in log_error FRONTEND path

Tom Lane <tgl@sss.pgh.pa.us>

From: Tom Lane <tgl@sss.pgh.pa.us>
To: Bryan Green <dbryan.green@gmail.com>
Cc: pgsql-hackers@postgresql.org
Date: 2025-10-13T15:48:59Z
Lists: pgsql-hackers
Bryan Green <dbryan.green@gmail.com> writes:
> I noticed that the log_error() utility function has a bug in its FRONTEND
> code path. The function uses fprintf() with a va_list argument, but
> fprintf() expects individual arguments. This should
> be vfprintf() instead.

Huh, that certainly appears broken, but isn't the non-FRONTEND
case equally broken?  write_stderr() doesn't expect a va_list
either.  I wonder if this code is ever reached at all.

			regards, tom lane



Commits

  1. Fix incorrect message-printing in win32security.c.