Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

prevent crashing from bad array index

  • Loading branch information...
commit 8f8bfb9ce74691cebdc704a7b65b38a8e0fee69f 1 parent a0dd323
Ching Yi, Chan authored
Showing with 6 additions and 0 deletions.
  1. +6 −0 libavcodec/wmv2.c
6 libavcodec/wmv2.c
View
@@ -85,6 +85,12 @@ void ff_mspel_motion(MpegEncContext *s,
src_x = s->mb_x * 16 + (motion_x >> 1);
src_y = s->mb_y * 16 + (motion_y >> 1);
+ if(dxy < 0)
+ {
+ av_log(s->avctx, AV_LOG_ERROR, "MUPLAYER-WILL-DIE: bad dxy index\n");
+ return ;
+ }
+
/* WARNING: do no forget half pels */
v_edge_pos = s->v_edge_pos;
src_x = av_clip(src_x, -16, s->width);
Please sign in to comment.
Something went wrong with that request. Please try again.