[Bf-blender-cvs] [0ae4d7d] master: Fix for GPU_materials_free accessing NULL pointer

Campbell Barton noreply at git.blender.org
Thu Dec 18 02:10:35 CET 2014


Commit: 0ae4d7d4059d1f8f6d1a2adcaae988b14c628c9f
Author: Campbell Barton
Date:   Thu Dec 18 02:14:51 2014 +0100
Branches: master
https://developer.blender.org/rB0ae4d7d4059d1f8f6d1a2adcaae988b14c628c9f

Fix for GPU_materials_free accessing NULL pointer

===================================================================

M	source/blender/gpu/intern/gpu_material.c

===================================================================

diff --git a/source/blender/gpu/intern/gpu_material.c b/source/blender/gpu/intern/gpu_material.c
index fcf3425..75a9572 100644
--- a/source/blender/gpu/intern/gpu_material.c
+++ b/source/blender/gpu/intern/gpu_material.c
@@ -1736,7 +1736,7 @@ void GPU_materials_free(void)
 		GPU_material_free(&ma->gpumaterial);
 
 	for (wo=G.main->world.first; wo; wo=wo->id.next)
-		GPU_material_free(&ma->gpumaterial);
+		GPU_material_free(&wo->gpumaterial);
 	
 	GPU_material_free(&defmaterial.gpumaterial);




More information about the Bf-blender-cvs mailing list