Closes issue64.
git-svn-id: file:///var/local/repositories/ffmpeg/trunk@12920
9553f0bf-9b14-0410-a0b8-
cfaf0461ba5b
#include "avformat.h"
#include "ac3_parser.h"
#include "raw.h"
+#include "crc.h"
#ifdef CONFIG_MUXERS
/* simple formats */
for(frames = 0; buf2 < end; frames++) {
if(ff_ac3_parse_header(buf2, &hdr) < 0)
break;
+ if(buf2 + hdr.frame_size > end ||
+ av_crc(av_crc_get_table(AV_CRC_16_ANSI), 0, buf2 + 2, hdr.frame_size - 2))
+ break;
buf2 += hdr.frame_size;
}
max_frames = FFMAX(max_frames, frames);