Merge commit '104a97beaffa6348e6fd2c2d07d67c1402322bb3'
authorMichael Niedermayer <michaelni@gmx.at>
Fri, 17 Jan 2014 15:38:10 +0000 (16:38 +0100)
committerMichael Niedermayer <michaelni@gmx.at>
Fri, 17 Jan 2014 15:38:10 +0000 (16:38 +0100)
* commit '104a97beaffa6348e6fd2c2d07d67c1402322bb3':
  buffersrc: handle non-refcounted frames in av_buffersrc_add_frame() correctly

Conflicts:
libavfilter/buffersrc.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
1  2 
libavfilter/buffersrc.c

@@@ -120,18 -94,16 +120,20 @@@ static int av_buffersrc_add_frame_inter
  {
      BufferSourceContext *s = ctx->priv;
      AVFrame *copy;
-     int ret;
+     int refcounted, ret;
  
 +    s->nb_failed_requests = 0;
 +
      if (!frame) {
          s->eof = 1;
          return 0;
      } else if (s->eof)
          return AVERROR(EINVAL);
  
+     refcounted = !!frame->buf[0];
 +    if (!(flags & AV_BUFFERSRC_FLAG_NO_CHECK_FORMAT)) {
 +
      switch (ctx->outputs[0]->type) {
      case AVMEDIA_TYPE_VIDEO:
          CHECK_VIDEO_PARAM_CHANGE(ctx, s, frame->width, frame->height,