try to fix crash when ChatCore destroyed and connection with model is still alive
This commit is contained in:
parent
2fc4439e16
commit
fa3ef0b1a8
4 changed files with 7 additions and 6 deletions
|
|
@ -118,6 +118,7 @@ ChatCore::ChatCore(const std::shared_ptr<linphone::ChatRoom> &chatRoom) : QObjec
|
||||||
ChatCore::~ChatCore() {
|
ChatCore::~ChatCore() {
|
||||||
lDebug() << "[ChatCore] delete" << this;
|
lDebug() << "[ChatCore] delete" << this;
|
||||||
mustBeInMainThread("~" + getClassName());
|
mustBeInMainThread("~" + getClassName());
|
||||||
|
if (mChatModelConnection) mChatModelConnection->disconnect();
|
||||||
emit mChatModel->removeListener();
|
emit mChatModel->removeListener();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -2082,13 +2082,13 @@
|
||||||
<context>
|
<context>
|
||||||
<name>ChatCore</name>
|
<name>ChatCore</name>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../core/chat/ChatCore.cpp" line="144"/>
|
<location filename="../../core/chat/ChatCore.cpp" line="145"/>
|
||||||
<source>info_toast_deleted_title</source>
|
<source>info_toast_deleted_title</source>
|
||||||
<extracomment>Deleted</extracomment>
|
<extracomment>Deleted</extracomment>
|
||||||
<translation type="unfinished"></translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../core/chat/ChatCore.cpp" line="146"/>
|
<location filename="../../core/chat/ChatCore.cpp" line="147"/>
|
||||||
<source>info_toast_deleted_message_history</source>
|
<source>info_toast_deleted_message_history</source>
|
||||||
<extracomment>Message history has been deleted</extracomment>
|
<extracomment>Message history has been deleted</extracomment>
|
||||||
<translation type="unfinished"></translation>
|
<translation type="unfinished"></translation>
|
||||||
|
|
|
||||||
|
|
@ -2059,13 +2059,13 @@
|
||||||
<context>
|
<context>
|
||||||
<name>ChatCore</name>
|
<name>ChatCore</name>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../core/chat/ChatCore.cpp" line="144"/>
|
<location filename="../../core/chat/ChatCore.cpp" line="145"/>
|
||||||
<source>info_toast_deleted_title</source>
|
<source>info_toast_deleted_title</source>
|
||||||
<extracomment>Deleted</extracomment>
|
<extracomment>Deleted</extracomment>
|
||||||
<translation>Deleted</translation>
|
<translation>Deleted</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../core/chat/ChatCore.cpp" line="146"/>
|
<location filename="../../core/chat/ChatCore.cpp" line="147"/>
|
||||||
<source>info_toast_deleted_message_history</source>
|
<source>info_toast_deleted_message_history</source>
|
||||||
<extracomment>Message history has been deleted</extracomment>
|
<extracomment>Message history has been deleted</extracomment>
|
||||||
<translation>Message history has been deleted</translation>
|
<translation>Message history has been deleted</translation>
|
||||||
|
|
|
||||||
|
|
@ -2059,13 +2059,13 @@
|
||||||
<context>
|
<context>
|
||||||
<name>ChatCore</name>
|
<name>ChatCore</name>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../core/chat/ChatCore.cpp" line="144"/>
|
<location filename="../../core/chat/ChatCore.cpp" line="145"/>
|
||||||
<source>info_toast_deleted_title</source>
|
<source>info_toast_deleted_title</source>
|
||||||
<extracomment>Deleted</extracomment>
|
<extracomment>Deleted</extracomment>
|
||||||
<translation>Supprimé</translation>
|
<translation>Supprimé</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../core/chat/ChatCore.cpp" line="146"/>
|
<location filename="../../core/chat/ChatCore.cpp" line="147"/>
|
||||||
<source>info_toast_deleted_message_history</source>
|
<source>info_toast_deleted_message_history</source>
|
||||||
<extracomment>Message history has been deleted</extracomment>
|
<extracomment>Message history has been deleted</extracomment>
|
||||||
<translation>L'historique des messages a été supprimé</translation>
|
<translation>L'historique des messages a été supprimé</translation>
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue