From 1d050ef1ae4443e787b8996cd4f1205505a85d12 Mon Sep 17 00:00:00 2001 From: Julien Wadel Date: Tue, 17 Jan 2023 17:20:20 +0100 Subject: [PATCH] Update lime url on migration for Linphone. Set old core url before migrating account parameters. Fix OpenSSL deployment on Windows. Update SDK to 5.2.10 # Conflicts: # CMakeLists.txt # linphone-sdk --- CHANGELOG.md | 3 ++- CMakeLists.txt | 7 ++++++- .../components/chat-room/ChatRoomModel.cpp | 12 ++++++----- .../src/components/core/CoreManager.cpp | 21 ++++++++++--------- 4 files changed, 26 insertions(+), 17 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index bbcd76956..f348a7433 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -14,7 +14,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ### Fixed - Crash at startup -- Update SDK to 5.2.8 +- Deploy missing OpenSSL libraries on Windows (fix blank message on image url) +- Update SDK to 5.2.10 ## 5.0.4 - 2022-12-28 diff --git a/CMakeLists.txt b/CMakeLists.txt index 10ad28314..4d92707c5 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -125,9 +125,13 @@ option(LINPHONE_SDK_MAKE_RELEASE_FILE_URL "Make a RELEASE file that work along c -if(WIN32 OR APPLE) +if(WIN32) + option(ENABLE_OPENSSL_EXPORT "Enable OpenSSL deployment" YES) +elseif(APPLE) + option(ENABLE_OPENSSL_EXPORT "Enable OpenSSL deployment" NO) else() option(ENABLE_V4L "Ability to capture and display video using libv4l2 or libv4l." YES) + option(ENABLE_OPENSSL_EXPORT "Enable OpenSSL deployment" NO) endif() option(ENABLE_RELATIVE_PREFIX "Set Internal packages relative to the binary" YES) @@ -150,6 +154,7 @@ list(APPEND APP_OPTIONS "-DENABLE_LDAP=${ENABLE_LDAP}") list(APPEND APP_OPTIONS "-DENABLE_NON_FREE_CODECS=${ENABLE_NON_FREE_CODECS}") list(APPEND APP_OPTIONS "-DENABLE_OPENH264=${ENABLE_OPENH264}") list(APPEND APP_OPTIONS "-DENABLE_QT_KEYCHAIN=${ENABLE_QT_KEYCHAIN}") +list(APPEND APP_OPTIONS "-DENABLE_OPENSSL_EXPORT=${ENABLE_OPENSSL_EXPORT}") list(APPEND APP_OPTIONS "-DENABLE_QRCODE=${ENABLE_QRCODE}") list(APPEND APP_OPTIONS "-DENABLE_SANITIZER=${ENABLE_SANITIZER}") list(APPEND APP_OPTIONS "-DENABLE_STRICT=${ENABLE_STRICT}") diff --git a/linphone-app/src/components/chat-room/ChatRoomModel.cpp b/linphone-app/src/components/chat-room/ChatRoomModel.cpp index 45de74dbe..096093168 100644 --- a/linphone-app/src/components/chat-room/ChatRoomModel.cpp +++ b/linphone-app/src/components/chat-room/ChatRoomModel.cpp @@ -1253,12 +1253,14 @@ void ChatRoomModel::onMessagesReceived(const std::shared_ptr void ChatRoomModel::onNewEvent(const std::shared_ptr & chatRoom, const std::shared_ptr & eventLog){ - if( eventLog->getType() == linphone::EventLog::Type::ConferenceCallEnded ){ - setMissedCallsCount(mMissedCallsCount+1); - }else if( eventLog->getType() == linphone::EventLog::Type::ConferenceCreated ){ - emit fullPeerAddressChanged(); + if(eventLog){ + if( eventLog->getType() == linphone::EventLog::Type::ConferenceCallEnded ){ + setMissedCallsCount(mMissedCallsCount+1); + }else if( eventLog->getType() == linphone::EventLog::Type::ConferenceCreated ){ + emit fullPeerAddressChanged(); + } + updateLastUpdateTime(); } - updateLastUpdateTime(); } void ChatRoomModel::onChatMessageReceived(const std::shared_ptr & chatRoom, const std::shared_ptr & eventLog) { diff --git a/linphone-app/src/components/core/CoreManager.cpp b/linphone-app/src/components/core/CoreManager.cpp index b04f30113..73db430d4 100644 --- a/linphone-app/src/components/core/CoreManager.cpp +++ b/linphone-app/src/components/core/CoreManager.cpp @@ -324,7 +324,10 @@ void CoreManager::migrate () { qInfo() << QStringLiteral("Migrate from old rc file (%1 to %2).") .arg(rcVersion).arg(Constants::RcVersionCurrent); - + if( !oldLimeServerUrl.empty()) { + mCore->setLimeX3DhServerUrl(""); + mCore->enableLimeX3Dh(true); + } bool setLimeServerUrl = false; for(const auto &account : getAccountList()){ auto params = account->getParams(); @@ -360,19 +363,17 @@ void CoreManager::migrate () { qInfo() << "Migrating" << accountIdentity << "for version 5. Video conference factory URI" << (exists ? std::string("unchanged") : std::string("= ") +Constants::DefaultVideoConferenceURI).c_str(); // note: using std::string.c_str() to avoid having double quotes in qInfo() } - - if(!oldLimeServerUrl.empty()) - newParams->setLimeServerUrl(oldLimeServerUrl); - else if( setLimeServerUrl) - newParams->setLimeServerUrl(Constants::DefaultLimeServerURL); + if(newParams->getLimeServerUrl().empty()){ + if(!oldLimeServerUrl.empty()) + newParams->setLimeServerUrl(oldLimeServerUrl); + else if( setLimeServerUrl) + newParams->setLimeServerUrl(Constants::DefaultLimeServerURL); + } account->setParams(newParams); } } - if( !oldLimeServerUrl.empty()) { - mCore->setLimeX3DhServerUrl(""); - mCore->enableLimeX3Dh(true); - }else if(setLimeServerUrl) { + if( oldLimeServerUrl.empty() && setLimeServerUrl) { mCore->enableLimeX3Dh(true); }