Fix watchdog to print inappropriate NOTICE message.
authorTatsuo Ishii <ishii@postgresql.org>
Fri, 25 Jul 2025 04:55:42 +0000 (13:55 +0900)
committerTatsuo Ishii <ishii@postgresql.org>
Fri, 25 Jul 2025 04:55:42 +0000 (13:55 +0900)
commit8c6a4f6beb62e6f88829108e06684aae25fb44a5
tree0a0d928fc404c97530eb2120233f7c441f9728a5
parent3604259c032847fdf20c5c5de5fbf88e43f3e505
Fix watchdog to print inappropriate NOTICE message.

read_ipc_socket_and_process() printed a notice message every time when
it wrote commands to IPC socket even if it was successful. Fix this to
print the notice message only when the write failed.

The reason why this bug was not recognized is, the message appears
only when log_min_messages is set to notice or higher.

Discussion: https://github.com/pgpool/pgpool2/issues/121
Backpatch-through: v4.2
src/watchdog/watchdog.c