Warning messages were previously sent to stderr
, which could cause them to
be misinterpreted as actual errors. This change redirects warning and informational
messages to stdout
instead, making it explicit that they are not errors and
preventing unintended stderr
handling.
To verify this behavior, added a test case triggering the simplest init warning I could find
(one that was actually not previously covered by tests): the -bind
“bad-port” message.
So, running the test commit on master (without the fix) causes the test framework to fail
during shutdown due to a non-empty stderr
buffer (treated as an error). With the fix
applied, the warning is correctly handled via stdout
, and the test passes as expected.