This is interesting.
When the content of the query has multiple elements, resulting reply.getContain() is not a valid XML document because it has multiple top-level elements.
This behaviour may appear in several queries. I.e. interface-information, software-information.

If returning a valid XML document in reply.getContain() is desired, I'd like to consider it a new issue. It may require a test suite and some fixes in this class to avoid these multiple top-level elements (independently of the message content, I'd would say :P)