summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChris Wilson <chris@chris-wilson.co.uk>2010-08-05 08:37:31 +0100
committerChris Wilson <chris@chris-wilson.co.uk>2010-08-05 08:39:15 +0100
commit66708fd8a98cc28dab756b9e29d026194ccdfcee (patch)
tree826ac55395dd3c4f8194dc62592eced59f9fc817
parent85cfe321805264686ef8989e45a911a999ed928a (diff)
intel: Check for a NULL src buffer prior to blt
This can only happen along a malloc failure path, but check anyway. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
-rw-r--r--src/mesa/drivers/dri/intel/intel_tex_copy.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/mesa/drivers/dri/intel/intel_tex_copy.c b/src/mesa/drivers/dri/intel/intel_tex_copy.c
index 224b506c05b..6efb2ddc553 100644
--- a/src/mesa/drivers/dri/intel/intel_tex_copy.c
+++ b/src/mesa/drivers/dri/intel/intel_tex_copy.c
@@ -102,7 +102,7 @@ do_copy_texsubimage(struct intel_context *intel,
GLcontext *ctx = &intel->ctx;
const struct intel_region *src = get_teximage_source(intel, internalFormat);
- if (!intelImage->mt || !src) {
+ if (!intelImage->mt || !src || !src->buffer) {
if (INTEL_DEBUG & DEBUG_FALLBACKS)
fprintf(stderr, "%s fail %p %p (0x%08x)\n",
__FUNCTION__, intelImage->mt, src, internalFormat);