From ddfa61ee194b9d4ec88d499c71cd6810e7f6a022 Mon Sep 17 00:00:00 2001 From: Alan Hourihane Date: Thu, 20 Jan 2005 13:24:08 +0000 Subject: Enclose passed macro values in brackets to ensure correct read/write span values. --- src/mesa/drivers/dri/i810/i810span.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/mesa/drivers/dri/i810') diff --git a/src/mesa/drivers/dri/i810/i810span.c b/src/mesa/drivers/dri/i810/i810span.c index 52fb1754df..eb32cb7c70 100644 --- a/src/mesa/drivers/dri/i810/i810span.c +++ b/src/mesa/drivers/dri/i810/i810span.c @@ -102,10 +102,10 @@ do { \ /* 16 bit depthbuffer functions. */ #define WRITE_DEPTH( _x, _y, d ) \ - *(GLushort *)(buf + _x*2 + _y*pitch) = d; + *(GLushort *)(buf + (_x)*2 + (_y)*pitch) = d; #define READ_DEPTH( d, _x, _y ) \ - d = *(GLushort *)(buf + _x*2 + _y*pitch); + d = *(GLushort *)(buf + (_x)*2 + (_y)*pitch); #define TAG(x) i810##x##_16 #include "depthtmp.h" -- cgit v1.2.3