Mercurial > mplayer.hg
diff libmpcodecs/vd_ffmpeg.c @ 32378:150df72e808f
Add a va_list version of mp_msg and use it to avoid yet another intermediate
buffer when printing FFmpeg messages in vd_ffmpeg.c
| author | reimar |
|---|---|
| date | Sat, 09 Oct 2010 12:12:14 +0000 |
| parents | c08363dc5320 |
| children | 2f1ccd169a7f |
line wrap: on
line diff
--- a/libmpcodecs/vd_ffmpeg.c Sat Oct 09 12:08:50 2010 +0000 +++ b/libmpcodecs/vd_ffmpeg.c Sat Oct 09 12:12:14 2010 +0000 @@ -185,7 +185,6 @@ AVClass *avc= ptr ? *(AVClass **)ptr : NULL; int type= MSGT_FIXME; int mp_level; - char buf[256]; switch(level){ case AV_LOG_VERBOSE: mp_level = MSGL_V ; break; @@ -226,8 +225,7 @@ } print_prefix= strchr(fmt, '\n') != NULL; - vsnprintf(buf, sizeof(buf), fmt, vl); - mp_msg(type, mp_level, buf); + mp_msg_va(type, mp_level, fmt, vl); } static void set_format_params(struct AVCodecContext *avctx, enum PixelFormat fmt){
