From b9fc61fd3087ad723d8d76bb24b2cd0d444bd6b1 Mon Sep 17 00:00:00 2001 From: James Booth Date: Thu, 20 Jun 2013 17:41:44 +0100 Subject: [PATCH] Moved stophe references in message send --- src/xmpp/message.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/xmpp/message.c b/src/xmpp/message.c index 1111d6f5..29d11958 100644 --- a/src/xmpp/message.c +++ b/src/xmpp/message.c @@ -68,8 +68,6 @@ message_send(const char * const msg, const char * const recipient) jid = recipient; } - xmpp_conn_t * const conn = connection_get_conn(); - xmpp_ctx_t * const ctx = connection_get_ctx(); if (prefs_get_boolean(PREF_STATES)) { if (!chat_session_exists(jid)) { chat_session_start(jid, TRUE); @@ -77,6 +75,8 @@ message_send(const char * const msg, const char * const recipient) } xmpp_stanza_t *message; + xmpp_conn_t * const conn = connection_get_conn(); + xmpp_ctx_t * const ctx = connection_get_ctx(); if (prefs_get_boolean(PREF_STATES) && chat_session_get_recipient_supports(jid)) { chat_session_set_active(jid); message = stanza_create_message(ctx, jid, STANZA_TYPE_CHAT,