lavfi/movie: set pkt->stream_index for flushing.
authorNicolas George <nicolas.george@normalesup.org>
Tue, 14 Aug 2012 09:08:48 +0000 (11:08 +0200)
committerNicolas George <nicolas.george@normalesup.org>
Thu, 16 Aug 2012 16:07:03 +0000 (18:07 +0200)
Otherwise, the value of stream_index is kept from the last packet
read, which is not necessarily the stream that needs flushing.

libavfilter/src_movie.c

index 09dfe5d..4ec80b7 100644 (file)
@@ -498,6 +498,7 @@ static int movie_push_frame(AVFilterContext *ctx, unsigned out_id)
                 }
                 return AVERROR_EOF;
             }
+            pkt->stream_index = movie->st[out_id].st->index;
             /* packet is already ready for flushing */
         } else {
             ret = av_read_frame(movie->format_ctx, &movie->pkt0);