Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCampbell Barton <ideasman42@gmail.com>2007-05-25 20:43:25 +0400
committerCampbell Barton <ideasman42@gmail.com>2007-05-25 20:43:25 +0400
commitf231bd0d5715ac67767f96f3a8d20ebf618f7b03 (patch)
tree34c05572641b2eafad9fa8e342724e0b05b6b3d8 /source/blender/python/api2_2x/Lattice.c
parenta21f8292d9aeff54153fc65560d56b3d4f33575a (diff)
Many long standing memory leaks fixed in the BPY api.
Data from Armature.c and logic.c still leaks. Mostly todo with PyList_Append adding a refcount and the bpython api not decrefing. Also added some features needed to fix a bug in mesh_clean.py (ob.pinShape and ob.activeShape)
Diffstat (limited to 'source/blender/python/api2_2x/Lattice.c')
-rw-r--r--source/blender/python/api2_2x/Lattice.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/source/blender/python/api2_2x/Lattice.c b/source/blender/python/api2_2x/Lattice.c
index 7b2ed57bf75..5c8df29d5d0 100644
--- a/source/blender/python/api2_2x/Lattice.c
+++ b/source/blender/python/api2_2x/Lattice.c
@@ -166,11 +166,11 @@ static PyObject *M_Lattice_New( PyObject * self, PyObject * args )
"expected string and int arguments (or nothing)" );
bl_Lattice = add_lattice( "Lattice" );
- bl_Lattice->id.us = 0;
- if( bl_Lattice )
+ if( bl_Lattice ) {
+ bl_Lattice->id.us = 0;
py_Lattice = Lattice_CreatePyObject( bl_Lattice );
- else
+ } else
return EXPP_ReturnPyObjError( PyExc_RuntimeError,
"couldn't create Lattice Object in Blender" );
if( !py_Lattice )