Revision: 19993
http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=19993
Author: campbellbarton
Date: 2009-04-30 02:51:11 +0200 (Thu, 30 Apr 2009)
Log Message:
-----------
Not sure why this INCREF is needed since making a replica wont use the
m_bytecode so why should it add a user?
Removed in 19974 but that crashes YoFrankie so adding back in for now.
Modified Paths:
--------------
trunk/blender/source/gameengine/GameLogic/SCA_PythonController.cpp
Modified: trunk/blender/source/gameengine/GameLogic/SCA_PythonController.cpp
===================================================================
--- trunk/blender/source/gameengine/GameLogic/SCA_PythonController.cpp
2009-04-30 00:47:50 UTC (rev 19992)
+++ trunk/blender/source/gameengine/GameLogic/SCA_PythonController.cpp
2009-04-30 00:51:11 UTC (rev 19993)
@@ -96,7 +96,11 @@
CValue* SCA_PythonController::GetReplica()
{
SCA_PythonController* replica = new SCA_PythonController(*this);
- // Copy the compiled bytecode if possible.
+
+ /* why is this needed at all??? - m_bytecode is NULL'd below so this
doesnt make sense
+ * but removing it crashes blender (with YoFrankie). so leave in for
now - Campbell */
+ Py_XINCREF(replica->m_bytecode);
+
Py_XINCREF(replica->m_function); // this is ok since its not set to NULL
replica->m_bModified = replica->m_bytecode == NULL;
_______________________________________________
Bf-blender-cvs mailing list
[email protected]
http://lists.blender.org/mailman/listinfo/bf-blender-cvs