Free stanza text and DiscoInfo features

This commit is contained in:
James Booth
2016-05-02 00:40:16 +01:00
parent 2bacd43a16
commit 31ab43ea2d
4 changed files with 9 additions and 3 deletions

View File

@@ -81,6 +81,7 @@ _message_handler(xmpp_conn_t *const conn, xmpp_stanza_t *const stanza, void *con
size_t text_size;
xmpp_stanza_to_text(stanza, &text, &text_size);
gboolean cont = plugins_on_message_stanza_receive(text);
xmpp_free(connection_get_ctx(), text);
if (!cont) {
return 1;
}
@@ -876,4 +877,5 @@ _send_message_stanza(xmpp_stanza_t *const stanza)
} else {
xmpp_send_raw_string(conn, "%s", text);
}
xmpp_free(connection_get_ctx(), text);
}