session & messages BUGFIX memory leaks
diff --git a/src/session.c b/src/session.c
index 5bc50b9..61d11ac 100644
--- a/src/session.c
+++ b/src/session.c
@@ -1273,6 +1273,7 @@
 
     if (msgtype == NC_MSG_REPLY) {
         *reply = parse_reply(session->ctx, xml, rpc);
+        lyxml_free(session->ctx, xml);
         if (!(*reply)) {
             return NC_MSG_ERROR;
         }