xmlstream: end the parser when the stream has ended
This commit is contained in:
parent
456dff0b61
commit
571774edb4
1 changed files with 1 additions and 0 deletions
|
@ -431,6 +431,7 @@ class XMLStream(asyncio.BaseProtocol):
|
||||||
log.debug("End of stream received")
|
log.debug("End of stream received")
|
||||||
self.disconnect_reason = "End of stream"
|
self.disconnect_reason = "End of stream"
|
||||||
self.abort()
|
self.abort()
|
||||||
|
return
|
||||||
elif self.xml_depth == 1:
|
elif self.xml_depth == 1:
|
||||||
# A stanza is an XML element that is a direct child of
|
# A stanza is an XML element that is a direct child of
|
||||||
# the root element, hence the check of depth == 1
|
# the root element, hence the check of depth == 1
|
||||||
|
|
Loading…
Reference in a new issue