Plug a couple of leaks in xmpp

Change-Id: Ic05489fe89860c590c6457568d14d63487e7054f