[Ffmpeg-cvslog] r7407 - trunk/libavcodec/wmv2.c

michael subversion
Wed Jan 3 12:32:02 CET 2007


Author: michael
Date: Wed Jan  3 12:32:02 2007
New Revision: 7407

Modified:
   trunk/libavcodec/wmv2.c

Log:
maybe fixing a segfault


Modified: trunk/libavcodec/wmv2.c
==============================================================================
--- trunk/libavcodec/wmv2.c	(original)
+++ trunk/libavcodec/wmv2.c	Wed Jan  3 12:32:02 2007
@@ -643,6 +643,12 @@
     v_edge_pos = s->v_edge_pos;
     src_x = clip(src_x, -16, s->width);
     src_y = clip(src_y, -16, s->height);
+
+    if(src_x<=-16 || src_x >= s->width)
+        dxy &= ~3;
+    if(src_y<=-16 || src_y >= s->height)
+        dxy &= ~4;
+
     linesize   = s->linesize;
     uvlinesize = s->uvlinesize;
     ptr = ref_picture[0] + (src_y * linesize) + src_x;




More information about the ffmpeg-cvslog mailing list