]> git.sesse.net Git - vlc/commitdiff
avcodec: flag blocks as corrupted if avpacket tells it is
authorIlkka Ollakka <ileoo@videolan.org>
Fri, 15 Mar 2013 11:33:14 +0000 (13:33 +0200)
committerIlkka Ollakka <ileoo@videolan.org>
Sun, 17 Mar 2013 15:07:19 +0000 (17:07 +0200)
modules/codec/avcodec/encoder.c

index 930636e5dda15fae634faea73a916124014a417e..a9c700be9b1439f39813828e5689cd8f02592ecc 100644 (file)
@@ -1035,6 +1035,8 @@ static block_t *EncodeVideo( encoder_t *p_enc, picture_t *p_pict )
 
     p_block->i_pts = av_pkt.pts;
     p_block->i_dts = av_pkt.dts;
+    if( unlikely( av_pkt.flags & AV_PKT_FLAG_CORRUPT ) )
+        p_block->i_flags |= BLOCK_FLAG_CORRUPTED;
 #endif
 
     switch ( p_sys->p_context->coded_frame->pict_type )