diff mbox

aplay: Fix VU-meter stdout/stderr mess

Message ID 1402622929.875823920@f438.i.mail.ru (mailing list archive)
State New, archived
Headers show

Commit Message

Sergey June 13, 2014, 1:28 a.m. UTC
Commit 6bbeb78d forgot to change some of VU-meter output to stderr.
This patch makes the output of `aplay -vvv` consistent again.
---
 aplay/aplay.c |    6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)
diff mbox

Patch

diff --git a/aplay/aplay.c b/aplay/aplay.c
index 33a8ed5..77e40a3 100644
--- a/aplay/aplay.c
+++ b/aplay/aplay.c
@@ -1774,12 +1774,12 @@  static void compute_max_peak(u_char *data, size_t count)
 		fflush(stderr);
 	}
 	else if(verbose==3) {
-		printf(_("Max peak (%li samples): 0x%08x "), (long)ocount, max_peak[0]);
+		fprintf(stderr, _("Max peak (%li samples): 0x%08x "), (long)ocount, max_peak[0]);
 		for (val = 0; val < 20; val++)
 			if (val <= perc[0] / 5)
-				putchar('#');
+				putc('#', stderr);
 			else
-				putchar(' ');
+				putc(' ', stderr);
 		fprintf(stderr, " %i%%\n", perc[0]);
 		fflush(stderr);
 	}