瀏覽代碼

make hotkey-driven garbage reporting dev-only

Darren Ranalli 15 年之前
父節點
當前提交
294e536d65
共有 1 個文件被更改,包括 2 次插入0 次删除
  1. 2 0
      direct/src/showbase/GarbageReport.py

+ 2 - 0
direct/src/showbase/GarbageReport.py

@@ -553,6 +553,8 @@ def checkForGarbageLeaks():
     return numGarbage
 
 def b_checkForGarbageLeaks(wantReply=False):
+    if not __dev__:
+        return 0
     # does a garbage collect on the client and the AI
     # returns number of client garbage leaks
     # logs leak info and terminates (if configured to do so)