summaryrefslogtreecommitdiff
path: root/src/mesa/drivers/dri
diff options
context:
space:
mode:
authorDave Airlie <airlied@redhat.com>2008-04-18 12:12:53 +1000
committerDave Airlie <airlied@panoply-rh.(none)>2008-04-18 12:13:13 +1000
commitf2a6404ef39b4985788aaf9ec8b540704e5aa92b (patch)
tree3e88fdddaed01ce92c1891a27f185cc845fa8796 /src/mesa/drivers/dri
parent008653ac55776d6b1c6d1627ad20937aa1c4dbda (diff)
i915: check for depth region before accounting its buffer size
fd.o bz #15573
Diffstat (limited to 'src/mesa/drivers/dri')
-rw-r--r--src/mesa/drivers/dri/i915/i915_vtbl.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/mesa/drivers/dri/i915/i915_vtbl.c b/src/mesa/drivers/dri/i915/i915_vtbl.c
index 5cf74d5906..135bfaa265 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) {