From 9bc70e29e8c3c4ec2588df92baf4f1a10f01ff27 Mon Sep 17 00:00:00 2001 From: James Booth Date: Sun, 3 Feb 2013 22:56:23 +0000 Subject: [PATCH] Removed jabber_restart function --- src/profanity.c | 1 - src/xmpp/connection.c | 12 ++++-------- src/xmpp/xmpp.h | 1 - 3 files changed, 4 insertions(+), 10 deletions(-) diff --git a/src/profanity.c b/src/profanity.c index 30a438e1..c9f78e3d 100644 --- a/src/profanity.c +++ b/src/profanity.c @@ -233,7 +233,6 @@ prof_handle_disconnect(const char * const jid) jabber_disconnect(); contact_list_clear(); chat_sessions_clear(); - jabber_restart(); ui_disconnected(); title_bar_set_status(PRESENCE_OFFLINE); status_bar_clear_message(); diff --git a/src/xmpp/connection.c b/src/xmpp/connection.c index 995617a1..d7ed95af 100644 --- a/src/xmpp/connection.c +++ b/src/xmpp/connection.c @@ -96,14 +96,6 @@ jabber_init(const int disable_tls) caps_init(); } -void -jabber_restart(void) -{ - jabber_conn.conn_status = JABBER_STARTED; - jabber_conn.presence_type = PRESENCE_OFFLINE; - FREE_SET_NULL(jabber_conn.presence_message); -} - jabber_conn_status_t jabber_connect_with_account(ProfAccount *account, const char * const passwd) { @@ -159,6 +151,10 @@ jabber_disconnect(void) } connection_free_resources(); } + + jabber_conn.conn_status = JABBER_STARTED; + jabber_conn.presence_type = PRESENCE_OFFLINE; + FREE_SET_NULL(jabber_conn.presence_message); } void diff --git a/src/xmpp/xmpp.h b/src/xmpp/xmpp.h index 9ecdd5ba..10c454c6 100644 --- a/src/xmpp/xmpp.h +++ b/src/xmpp/xmpp.h @@ -62,7 +62,6 @@ const char * jabber_get_jid(void); jabber_conn_status_t jabber_get_connection_status(void); jabber_presence_t jabber_get_presence_type(void); char * jabber_get_presence_message(void); -void jabber_restart(void); void jabber_set_autoping(int seconds); char* jabber_get_account_name(void);