# HG changeset patch # User bae # Date 1311164288 -14400 # Node ID a6dbbf4eb30fa5916e91ec1283dd1e377de65879 # Parent 7f82305d48d10800ca54d0a0420f30870b1ae2f0 7044285: 64 bit VM crashes in Java_sun_java2d_loops_MaskFill_MaskFill Reviewed-by: jgodinez, prr diff -r 7f82305d48d1 -r a6dbbf4eb30f jdk/src/share/native/sun/java2d/loops/GraphicsPrimitiveMgr.h --- a/jdk/src/share/native/sun/java2d/loops/GraphicsPrimitiveMgr.h Tue Jul 19 14:09:25 2011 -0700 +++ b/jdk/src/share/native/sun/java2d/loops/GraphicsPrimitiveMgr.h Wed Jul 20 16:18:08 2011 +0400 @@ -30,6 +30,8 @@ extern "C" { #endif +#include + #include "java_awt_AlphaComposite.h" #include "SurfaceData.h" @@ -484,7 +486,9 @@ #define ArraySize(A) (sizeof(A) / sizeof(A[0])) #define PtrAddBytes(p, b) ((void *) (((intptr_t) (p)) + (b))) -#define PtrCoord(p, x, xinc, y, yinc) PtrAddBytes(p, (y)*(yinc) + (x)*(xinc)) +#define PtrCoord(p, x, xinc, y, yinc) PtrAddBytes(p, \ + ((ptrdiff_t)(y))*(yinc) + \ + ((ptrdiff_t)(x))*(xinc)) /* * The function to call with an array of NativePrimitive structures