From e72a44215312ae1f3c812ba28e47b4aec3589de9 Mon Sep 17 00:00:00 2001 From: Pierre Willenbrock Date: Fri, 12 Dec 2008 21:18:23 +0100 Subject: [PATCH] intel: Don't steal renderbuffer from caller in intel_miptree_create_for_region Fixes double-frees of some regions, once from the renderbuffer code and once from the miptree itself. Bug #19062 --- src/mesa/drivers/dri/intel/intel_mipmap_tree.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/mesa/drivers/dri/intel/intel_mipmap_tree.c b/src/mesa/drivers/dri/intel/intel_mipmap_tree.c index c677ddd63c5..bf1c3f03f0e 100644 --- a/src/mesa/drivers/dri/intel/intel_mipmap_tree.c +++ b/src/mesa/drivers/dri/intel/intel_mipmap_tree.c @@ -163,7 +163,7 @@ intel_miptree_create_for_region(struct intel_context *intel, mt->pitch = region->pitch; #endif - mt->region = region; + intel_region_reference(&mt->region, region); return mt; } -- 2.30.2