From: Dave Airlie Date: Fri, 18 Apr 2008 02:12:53 +0000 (+1000) Subject: i915: check for depth region before accounting its buffer size X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=f2a6404ef39b4985788aaf9ec8b540704e5aa92b;p=mesa.git i915: check for depth region before accounting its buffer size fd.o bz #15573 --- diff --git a/src/mesa/drivers/dri/i915/i915_vtbl.c b/src/mesa/drivers/dri/i915/i915_vtbl.c index 5cf74d59061..135bfaa265d 100644 --- a/src/mesa/drivers/dri/i915/i915_vtbl.c +++ b/src/mesa/drivers/dri/i915/i915_vtbl.c @@ -322,7 +322,8 @@ i915_emit_state(struct intel_context *intel) ret = 0; if (dirty & I915_UPLOAD_BUFFERS) { ret |= dri_bufmgr_check_aperture_space(state->draw_region->buffer); - ret |= dri_bufmgr_check_aperture_space(state->depth_region->buffer); + if (state->depth_region) + ret |= dri_bufmgr_check_aperture_space(state->depth_region->buffer); } if (dirty & I915_UPLOAD_TEX_ALL) {