changeset 3891:e87f69a44813

a52: CRC check for AC3 frames
author arpi
date Sun, 30 Dec 2001 04:44:20 +0000
parents c3e62caf9ec6
children 097f2bef902b
files dec_audio.c
diffstat 1 files changed, 4 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/dec_audio.c	Sun Dec 30 04:42:42 2001 +0000
+++ b/dec_audio.c	Sun Dec 30 04:44:20 2001 +0000
@@ -246,6 +246,10 @@
     sh_audio->samplerate=sample_rate;
     sh_audio->i_bps=bit_rate/8;
     demux_read_data(sh_audio->ds,sh_audio->a_in_buffer+7,length-7);
+    
+    if(crc16_block(sh_audio->a_in_buffer+2,length-2)!=0)
+	mp_msg(MSGT_DECAUDIO,MSGL_STATUS,"a52: CRC check failed!  \n");
+    
     return length;
 }