From 3a1bd6a2c9a5ee4687be63837023dbe4cdfcb24d Mon Sep 17 00:00:00 2001 From: Ronan Abhamon Date: Fri, 21 Apr 2017 16:39:33 +0200 Subject: [PATCH] fix(src/components/chat/ChatModel): handle correctly call events --- linphone-desktop/src/components/chat/ChatModel.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/linphone-desktop/src/components/chat/ChatModel.cpp b/linphone-desktop/src/components/chat/ChatModel.cpp index 62e6e5f52..19beb1e19 100644 --- a/linphone-desktop/src/components/chat/ChatModel.cpp +++ b/linphone-desktop/src/components/chat/ChatModel.cpp @@ -567,7 +567,10 @@ void ChatModel::resetMessagesCount () { // ----------------------------------------------------------------------------- void ChatModel::handleCallStateChanged (const shared_ptr &call, linphone::CallState state) { - if (mChatRoom == call->getChatRoom() && (state == linphone::CallStateEnd || state == linphone::CallStateError)) + if ( + (state == linphone::CallStateEnd || state == linphone::CallStateError) && + mChatRoom == CoreManager::getInstance()->getCore()->getChatRoom(call->getRemoteAddress()) + ) insertCall(call->getCallLog()); }