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>2009-05-08 02:06:27 +0400
committerCampbell Barton <ideasman42@gmail.com>2009-05-08 02:06:27 +0400
commitcdba1ddd5d454aca4d39dbb01866c155421b5d11 (patch)
tree61daee071a00e619f20ac04851a781df40e6410b
parente1c958c3648ef903777f49b9fb6d4230af316885 (diff)
BGE Python owned proxies had a problem being decref'd twice, this would crash on freeing KX_Vertex/Poly Proxy types when python was compiled with debug options enabled.
add_mesh_torus.py wasnt tested from update, will go through all edited scripts and test :\
-rw-r--r--release/scripts/add_mesh_torus.py2
-rw-r--r--source/gameengine/Expressions/PyObjectPlus.cpp1
2 files changed, 2 insertions, 1 deletions
diff --git a/release/scripts/add_mesh_torus.py b/release/scripts/add_mesh_torus.py
index f2fc53ef275..2941c56420e 100644
--- a/release/scripts/add_mesh_torus.py
+++ b/release/scripts/add_mesh_torus.py
@@ -62,7 +62,7 @@ def main():
BPyAddMesh.add_mesh_simple('Torus', verts, [], faces)
-if math:
+if cos and sin and pi:
main()
else:
Blender.Draw.PupMenu("Error%t|This script requires a full python installation")
diff --git a/source/gameengine/Expressions/PyObjectPlus.cpp b/source/gameengine/Expressions/PyObjectPlus.cpp
index 82f67a9b007..7d302246c70 100644
--- a/source/gameengine/Expressions/PyObjectPlus.cpp
+++ b/source/gameengine/Expressions/PyObjectPlus.cpp
@@ -95,6 +95,7 @@ void PyObjectPlus::py_base_dealloc(PyObject *self) // python wrapper
PyObjectPlus *self_plus= BGE_PROXY_REF(self);
if(self_plus) {
if(BGE_PROXY_PYOWNS(self)) { /* Does python own this?, then delete it */
+ self_plus->m_proxy = NULL; /* Need this to stop ~PyObjectPlus from decrefing m_proxy otherwise its decref'd twice and py-debug crashes */
delete self_plus;
}