about summary refs log tree commit diff stats
path: root/src/xmpp
diff options
context:
space:
mode:
authorJames Booth <boothj5@gmail.com>2015-10-15 01:19:24 +0100
committerJames Booth <boothj5@gmail.com>2015-10-15 01:19:24 +0100
commit904a5a81cfcc19c7029f0a961cfb97f7d1a2fe9f (patch)
tree92a1a43f43f7a5fbbd022fe9b4ccd2fbb1390cb8 /src/xmpp
parentfb60a755e50e8edf8c00ebbf2ba1e707da6ec101 (diff)
downloadprofani-tty-904a5a81cfcc19c7029f0a961cfb97f7d1a2fe9f.tar.gz
Add ability to script commands after connect
Diffstat (limited to 'src/xmpp')
-rw-r--r--src/xmpp/connection.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/xmpp/connection.c b/src/xmpp/connection.c
index ba694bfd..2b7db8be 100644
--- a/src/xmpp/connection.c
+++ b/src/xmpp/connection.c
@@ -482,6 +482,8 @@ _connection_handler(xmpp_conn_t * const conn,
     // login success
     if (status == XMPP_CONN_CONNECT) {
         log_debug("Connection handler: XMPP_CONN_CONNECT");
+        jabber_conn.conn_status = JABBER_CONNECTED;
+
         int secured = xmpp_conn_is_secured(jabber_conn.conn);
 
         // logged in with account
@@ -520,8 +522,6 @@ _connection_handler(xmpp_conn_t * const conn,
             iq_enable_carbons();
         }
 
-        jabber_conn.conn_status = JABBER_CONNECTED;
-
         if (prefs_get_reconnect() != 0) {
             if (reconnect_timer) {
                 g_timer_destroy(reconnect_timer);