1
1
mirror of https://github.com/profanity-im/profanity.git synced 2025-02-02 15:08:15 -05:00

jabber.c: added assert before reconnect_timer allocation

Development build will be terminated if reconnect_timer was allocated
previously and wasn't destroyed.
This commit is contained in:
Dmitry Podgorny 2013-01-07 20:24:04 +02:00
parent 5e8d9e942b
commit d0ab292d73

View File

@ -22,6 +22,7 @@
#include <string.h>
#include <stdlib.h>
#include <assert.h>
#include <strophe.h>
@ -800,6 +801,7 @@ _connection_handler(xmpp_conn_t * const conn,
} else if (jabber_conn.conn_status == JABBER_CONNECTED) {
prof_handle_lost_connection();
if (prefs_get_reconnect() != 0) {
assert(reconnect_timer == NULL);
reconnect_timer = g_timer_new();
}
xmpp_stop(ctx);