[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [50510] branches/soc-2012-bratwurst/source /blender/assimp/MeshImporter.cpp: - bf_assimp: fix mesh ref counting bug.

Alexander Gessler alexander.gessler at gmx.net
Mon Sep 10 22:35:21 CEST 2012


Revision: 50510
          http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=50510
Author:   aramis_acg
Date:     2012-09-10 20:35:20 +0000 (Mon, 10 Sep 2012)
Log Message:
-----------
- bf_assimp: fix mesh ref counting bug.

Modified Paths:
--------------
    branches/soc-2012-bratwurst/source/blender/assimp/MeshImporter.cpp

Modified: branches/soc-2012-bratwurst/source/blender/assimp/MeshImporter.cpp
===================================================================
--- branches/soc-2012-bratwurst/source/blender/assimp/MeshImporter.cpp	2012-09-10 17:38:48 UTC (rev 50509)
+++ branches/soc-2012-bratwurst/source/blender/assimp/MeshImporter.cpp	2012-09-10 20:35:20 UTC (rev 50510)
@@ -113,6 +113,8 @@
 	Mesh* const old_mesh = static_cast<Mesh*>(ob->data);
 
 	ob->data = mesh;
+	id_us_plus((ID *)mesh);
+
 	if (--old_mesh->id.us == 0) {
 		BKE_libblock_free(&G.main->mesh, old_mesh);
 	}




More information about the Bf-blender-cvs mailing list