Skip to content

Commit 514731a

Browse files
committed
pg_receivewal: Improve verbose mode
Some informational messages showed up even if verbose mode was not used. Move them to verbose mode. Author: Michael Paquier <michael.paquier@gmail.com> Reviewed-by: Daniel Gustafsson <daniel@yesql.se>
1 parent 0659465 commit 514731a

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

src/bin/pg_basebackup/pg_receivewal.c

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -120,7 +120,7 @@ stop_streaming(XLogRecPtr xlogpos, uint32 timeline, bool segment_finished)
120120
* slightly before the end of the WAL that we received on the previous
121121
* timeline, but it's close enough for reporting purposes.
122122
*/
123-
if (prevtimeline != 0 && prevtimeline != timeline)
123+
if (verbose && prevtimeline != 0 && prevtimeline != timeline)
124124
fprintf(stderr, _("%s: switched to timeline %u at %X/%X\n"),
125125
progname, timeline,
126126
(uint32) (prevpos >> 32), (uint32) prevpos);
@@ -130,8 +130,9 @@ stop_streaming(XLogRecPtr xlogpos, uint32 timeline, bool segment_finished)
130130

131131
if (time_to_abort)
132132
{
133-
fprintf(stderr, _("%s: received interrupt signal, exiting\n"),
134-
progname);
133+
if (verbose)
134+
fprintf(stderr, _("%s: received interrupt signal, exiting\n"),
135+
progname);
135136
return true;
136137
}
137138
return false;

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy