mirror of
https://github.com/panda3d/panda3d.git
synced 2025-10-03 10:22:45 -04:00
make sure garbage collection is enabled when Python breaks to the prompt
This commit is contained in:
parent
0d3349bac0
commit
69985789f1
@ -2306,7 +2306,13 @@ class ShowBase(DirectObject.DirectObject):
|
||||
self.startDirect(fWantDirect = fDirect, fWantTk = fTk, fWantWx = fWx)
|
||||
|
||||
def run(self):
|
||||
self.taskMgr.run()
|
||||
try:
|
||||
self.taskMgr.run()
|
||||
except:
|
||||
# make sure gc is enabled when we break out to the prompt
|
||||
gc.enable()
|
||||
else:
|
||||
gc.enable()
|
||||
|
||||
def _garbageCollect(self, task=None):
|
||||
# enable automatic garbage collection
|
||||
|
Loading…
x
Reference in New Issue
Block a user