Browse Source

fixing leaks

Joe Shochet 23 years ago
parent
commit
c56d92f5d5
2 changed files with 3 additions and 2 deletions
  1. 1 2
      direct/src/distributed/DistributedObject.py
  2. 2 0
      direct/src/showbase/PythonUtil.py

+ 1 - 2
direct/src/distributed/DistributedObject.py

@@ -55,8 +55,7 @@ class DistributedObject(PandaObject):
     #    """
     #    For debugging purposes, this just prints out what got deleted
     #    """
-    #    DistributedObject.notify.debug("Destructing: " + self.__class__.__name__ +
-    #                                   " id: " + str(self.doId))
+    #    print ("Destructing: " + self.__class__.__name__ + " id: " + str(self.doId))
     #    PandaObject.__del__(self)
 
     def setNeverDisable(self, bool):

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

@@ -313,6 +313,8 @@ def intersection(a, b):
     """
     intersection(list, list):
     """
+    if not a: return []
+    if not b: return []
     c = a + b
     d = []
     for i in c: