From 3022129d85785fa0095e3bbf8df24988a21b1ee9 Mon Sep 17 00:00:00 2001 From: wm4 Date: Sat, 25 Feb 2012 13:49:29 +0100 Subject: osd: clear terminal OSD line with mp_msg() instead of printf If mplayer is started with -msglevel cplayer=-1, there can't be any terminal OSD output, but the terminal line was still cleared unconditionally. Fix this by using mp_msg(), which will throw away the output to clear the terminal if disabled. Fixes #154. --- mplayer.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mplayer.c b/mplayer.c index 1c2bc7efa3..e843c07436 100644 --- a/mplayer.c +++ b/mplayer.c @@ -1755,7 +1755,7 @@ static void update_osd_msg(struct MPContext *mpctx) // Clear the term osd line if (opts->term_osd && mpctx->terminal_osd_text[0]) { mpctx->terminal_osd_text[0] = '\0'; - printf("%s\n", opts->term_osd_esc); + mp_msg(MSGT_CPLAYER, MSGL_STATUS, "%s\n", opts->term_osd_esc); } } -- cgit v1.2.3