Fix memory leak with adhoc command sessions.

Fixes issue #155
This commit is contained in:
Lance Stout 2012-04-03 11:02:55 -07:00
parent 48504ed5e2
commit cdf0b353db

View file

@ -565,10 +565,11 @@ class XEP_0050(BasePlugin):
session -- All stored data relevant to the current
command session.
"""
sessionid = 'client:' + session['id']
try:
del self.sessions[session['id']]
except:
pass
del self.sessions[sessionid]
except Exception as e:
log.error("Error deleting adhoc command session: %s" % e.message)
def _handle_command_result(self, iq):
"""