소스 검색

added record-functor-creation-stacks config

Darren Ranalli 17 년 전
부모
커밋
5d256052e6
1개의 변경된 파일2개의 추가작업 그리고 1개의 파일을 삭제
  1. 2 1
      direct/src/showbase/PythonUtil.py

+ 2 - 1
direct/src/showbase/PythonUtil.py

@@ -3626,7 +3626,8 @@ class HierarchyException(Exception):
 # __dev__ is not defined at import time, call this after it's defined
 def recordFunctorCreationStacks():
     global Functor
-    if __dev__:
+    from pandac.PandaModules import ConfigConfigureGetConfigConfigShowbase as config
+    if __dev__ and config.GetBool('record-functor-creation-stacks', 1):
         if not hasattr(Functor, '_functorCreationStacksRecorded'):
             Functor = recordCreationStackStr(Functor)
             Functor._functorCreationStacksRecorded = True