From 30eb8286a2415570ac5515fb7fcc8c0ee56b4d6e Mon Sep 17 00:00:00 2001 From: Darren Ranalli Date: Tue, 10 Feb 2009 23:23:49 +0000 Subject: [PATCH] better runtime characteristics --- direct/src/showbase/ContainerLeakDetector.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/direct/src/showbase/ContainerLeakDetector.py b/direct/src/showbase/ContainerLeakDetector.py index cd813eff27..8857c9a28b 100755 --- a/direct/src/showbase/ContainerLeakDetector.py +++ b/direct/src/showbase/ContainerLeakDetector.py @@ -547,7 +547,7 @@ class FindContainers(Job): if hasLength or notDeadEnd: # prevent cycles in the references (i.e. base.loader.base) for goesThrough in parentObjRef.goesThroughGen(child): - pass + yield None if not goesThrough: objRef = ObjectRef(Indirection(evalStr='.__dict__'), id(child), parentObjRef) @@ -585,7 +585,7 @@ class FindContainers(Job): if hasLength or notDeadEnd: # prevent cycles in the references (i.e. base.loader.base) for goesThrough in parentObjRef.goesThroughGen(curObj[key]): - pass + yield None if not goesThrough: if curObj is __builtin__.__dict__: objRef = ObjectRef(Indirection(evalStr='%s' % key), @@ -636,7 +636,7 @@ class FindContainers(Job): if hasLength or notDeadEnd: # prevent cycles in the references (i.e. base.loader.base) for goesThrough in parentObjRef.goesThrough(curObj[index]): - pass + yield None if not goesThrough: objRef = ObjectRef(Indirection(evalStr='[%s]' % index), id(curObj[index]), parentObjRef)