From: Eric Anholt Date: Sat, 1 Apr 2006 00:57:57 +0000 (+0000) Subject: Don't index box by the box's index within numClipRects; just dereference it. X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=482d9dd21ddb7293a430ee1b34b6087391b064e1;p=mesa.git Don't index box by the box's index within numClipRects; just dereference it. Fixes drawing with more than one cliprect. (Keith Packard) --- diff --git a/src/mesa/drivers/dri/i915/intel_batchbuffer.c b/src/mesa/drivers/dri/i915/intel_batchbuffer.c index 974a2497e1d..5979e236bcd 100644 --- a/src/mesa/drivers/dri/i915/intel_batchbuffer.c +++ b/src/mesa/drivers/dri/i915/intel_batchbuffer.c @@ -655,10 +655,10 @@ void intelClearWithBlit(GLcontext *ctx, GLbitfield flags, GLboolean all, drm_clip_rect_t b; if (!all) { - GLint x = box[i].x1; - GLint y = box[i].y1; - GLint w = box[i].x2 - x; - GLint h = box[i].y2 - y; + GLint x = box->x1; + GLint y = box->y1; + GLint w = box->x2 - x; + GLint h = box->y2 - y; if (x < cx) w -= cx - x, x = cx; if (y < cy) h -= cy - y, y = cy;