From 70bd39eb74411f4dd0bb7adaccff54117a833932 Mon Sep 17 00:00:00 2001 From: Jfreegman Date: Mon, 11 Apr 2016 18:50:28 -0400 Subject: [PATCH] Fix small bug --- src/chat.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/chat.c b/src/chat.c index 2699f7f..cdebf8d 100644 --- a/src/chat.c +++ b/src/chat.c @@ -215,13 +215,14 @@ static void chat_onConnectionChange(ToxWindow *self, Tox *m, uint32_t num, TOX_C char nick[TOX_MAX_NAME_LENGTH]; get_nick_truncate(m, nick, num); + TOX_CONNECTION prev_status = statusbar->connection; statusbar->connection = connection_status; if (user_settings->show_connection_msg == SHOW_WELCOME_MSG_OFF) { return; } - if (connection_status != TOX_CONNECTION_NONE && statusbar->connection == TOX_CONNECTION_NONE) { + if (prev_status == TOX_CONNECTION_NONE) { Friends.list[num].is_typing = user_settings->show_typing_other == SHOW_TYPING_ON ? tox_friend_get_typing(m, num, NULL) : false; chat_resume_file_senders(self, m, num);