From 5b29ce713255d9d983397ca4f419bbf496da2af7 Mon Sep 17 00:00:00 2001 From: Jfreegman Date: Thu, 3 Mar 2016 20:49:48 -0500 Subject: [PATCH] Fix bug preventing friend connection status from changing --- src/chat.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/chat.c b/src/chat.c index fd31c19..7ae2d0e 100644 --- a/src/chat.c +++ b/src/chat.c @@ -219,6 +219,8 @@ static void chat_onConnectionChange(ToxWindow *self, Tox *m, uint32_t num, TOX_C return; } + statusbar->connection = connection_status; + if (connection_status != TOX_CONNECTION_NONE && statusbar->connection == TOX_CONNECTION_NONE) { Friends.list[num].is_typing = user_settings->show_typing_other == SHOW_TYPING_ON ? tox_friend_get_typing(m, num, NULL) : false; @@ -239,8 +241,6 @@ static void chat_onConnectionChange(ToxWindow *self, Tox *m, uint32_t num, TOX_C line_info_add(self, timefrmt, nick, NULL, DISCONNECTION, 0, RED, msg); write_to_log(msg, nick, ctx->log, true); } - - statusbar->connection = connection_status; } static void chat_onTypingChange(ToxWindow *self, Tox *m, uint32_t num, bool is_typing)