diff options
author | Xiang, Haihao <haihao.xiang@intel.com> | 2008-12-12 10:02:05 +0800 |
---|---|---|
committer | Xiang, Haihao <haihao.xiang@intel.com> | 2008-12-12 10:05:00 +0800 |
commit | 251bc8383d0ec01aaafb0e4eea9105ef1756891c (patch) | |
tree | 97f1af837086ebfbd04ba8a0ae1a836a4706f604 | |
parent | 456dbb143a0d11b69d8af0d493cd84efb0596273 (diff) |
intel: check for null texture. (fix #13902)
(cherry picked from commit 8b69c42b356d51c3a37bc0af41738b016c2adc5b)
-rw-r--r-- | src/mesa/drivers/dri/intel/intel_mipmap_tree.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/mesa/drivers/dri/intel/intel_mipmap_tree.c b/src/mesa/drivers/dri/intel/intel_mipmap_tree.c index 9be7e02eff..d8202aad1c 100644 --- a/src/mesa/drivers/dri/intel/intel_mipmap_tree.c +++ b/src/mesa/drivers/dri/intel/intel_mipmap_tree.c @@ -111,9 +111,9 @@ intel_miptree_create(struct intel_context *intel, first_level, last_level, width0, height0, depth0, cpp, compress_byte); /* - * pitch == 0 indicates the null texture + * pitch == 0 || height == 0 indicates the null texture */ - if (!mt || !mt->pitch) + if (!mt || !mt->pitch || !mt->total_height) return NULL; mt->region = intel_region_alloc(intel, |