avutil/log: dont count&print repeats for empty strings

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
Michael Niedermayer 2013-04-26 23:41:29 +02:00
parent 9a0aa8d02a
commit a057552212

View File

@ -222,7 +222,7 @@ void av_log_default_callback(void* ptr, int level, const char* fmt, va_list vl)
is_atty = isatty(2) ? 1 : -1;
#endif
if (print_prefix && (flags & AV_LOG_SKIP_REPEATED) && !strcmp(line, prev)){
if (print_prefix && (flags & AV_LOG_SKIP_REPEATED) && !strcmp(line, prev) && *line){
count++;
if (is_atty == 1)
fprintf(stderr, " Last message repeated %d times\r", count);