Commit 7055cdac authored by Benoit Fouet's avatar Benoit Fouet

Inform user when bitstream filter fails.

Originally committed as revision 11587 to svn://svn.ffmpeg.org/ffmpeg/trunk
parent c448a096
...@@ -415,9 +415,15 @@ static void write_frame(AVFormatContext *s, AVPacket *pkt, AVCodecContext *avctx ...@@ -415,9 +415,15 @@ static void write_frame(AVFormatContext *s, AVPacket *pkt, AVCodecContext *avctx
&new_pkt.data, &new_pkt.size, &new_pkt.data, &new_pkt.size,
pkt->data, pkt->size, pkt->data, pkt->size,
pkt->flags & PKT_FLAG_KEY); pkt->flags & PKT_FLAG_KEY);
if(a){ if(a>0){
av_free_packet(pkt); av_free_packet(pkt);
new_pkt.destruct= av_destruct_packet; new_pkt.destruct= av_destruct_packet;
} else if(a<0){
fprintf(stderr, "%s failed for stream %d, codec %s"
, bsfc->filter->name
, pkt->stream_index
, avctx->codec ? avctx->codec->name : "copy");
print_error("", a);
} }
*pkt= new_pkt; *pkt= new_pkt;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment