diff --git a/coreapi/chat.c b/coreapi/chat.c index 3a15ea552..1f1afbb1f 100644 --- a/coreapi/chat.c +++ b/coreapi/chat.c @@ -1347,6 +1347,7 @@ static void _linphone_chat_message_destroy(LinphoneChatMessage* msg) { linphone_content_uninit(msg->file_transfer_information); ms_free(msg->file_transfer_information); } + ms_message("LinphoneChatMessage [%p] destroyed.",msg); } diff --git a/tester/tester.c b/tester/tester.c index 07ace6956..9b796da4c 100644 --- a/tester/tester.c +++ b/tester/tester.c @@ -252,6 +252,7 @@ void linphone_core_manager_stop(LinphoneCoreManager *mgr){ } void linphone_core_manager_destroy(LinphoneCoreManager* mgr) { + if (mgr->stat.last_received_chat_message) linphone_chat_message_unref(mgr->stat.last_received_chat_message); if (mgr->lc) linphone_core_destroy(mgr->lc); if (mgr->identity) linphone_address_destroy(mgr->identity); ms_free(mgr);