# HG changeset patch # User bcoudurier # Date 1245018868 0 # Node ID 5484569026567a1a297299d63369941330d08d93 # Parent 3aabdadf9d5fe543f907628838fb58a7e54a13cc check if frame size matches old sys and assumes corrupted input, fixes #1192 diff -r 3aabdadf9d5f -r 548456902656 dv.c --- a/dv.c Sat Jun 13 22:45:58 2009 +0000 +++ b/dv.c Sun Jun 14 22:34:28 2009 +0000 @@ -322,7 +322,7 @@ uint8_t *ppcm[4] = {0}; if (buf_size < DV_PROFILE_BYTES || - !(c->sys = dv_frame_profile(buf)) || + !(c->sys = dv_frame_profile(c->sys, buf, buf_size)) || buf_size < c->sys->frame_size) { return -1; /* Broken frame, or not enough data */ } @@ -421,7 +421,7 @@ url_fseek(s->pb, -DV_PROFILE_BYTES, SEEK_CUR) < 0) return AVERROR(EIO); - c->dv_demux->sys = dv_frame_profile(c->buf); + c->dv_demux->sys = dv_frame_profile(c->dv_demux->sys, c->buf, DV_PROFILE_BYTES); if (!c->dv_demux->sys) { av_log(s, AV_LOG_ERROR, "Can't determine profile of DV input stream.\n"); return -1;