Browse Source

avfilter/vf_fps: make sure the fifo is not empty before using it

Fixes Ticket2905

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
tags/n2.1
Michael Niedermayer 11 years ago
parent
commit
cdd5df8189
1 changed files with 1 additions and 1 deletions
  1. +1
    -1
      libavfilter/vf_fps.c

+ 1
- 1
libavfilter/vf_fps.c View File

@@ -205,7 +205,7 @@ static int filter_frame(AVFilterLink *inlink, AVFrame *buf)
}

/* now wait for the next timestamp */
if (buf->pts == AV_NOPTS_VALUE) {
if (buf->pts == AV_NOPTS_VALUE || av_fifo_size(s->fifo) <= 0) {
return write_to_fifo(s->fifo, buf);
}



Loading…
Cancel
Save