From 0eabd40982c1f8cd4275f0858d27584f6c1a25ac Mon Sep 17 00:00:00 2001 From: Cyril Soler Date: Fri, 18 Aug 2023 22:25:59 +0200 Subject: [PATCH] added some missing IndicateConfigChanged() calls that would loose friends on crash right after after addign them --- src/pqi/authgpg.cc | 2 +- src/pqi/p3peermgr.cc | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/src/pqi/authgpg.cc b/src/pqi/authgpg.cc index ee5324d73..eebab962c 100644 --- a/src/pqi/authgpg.cc +++ b/src/pqi/authgpg.cc @@ -616,7 +616,7 @@ bool AuthPGP::AllowConnection(const RsPgpId& gpg_id, bool accept) instance()->mPgpHandler->setAcceptConnexion(gpg_id,accept) ; } - instance()->IndicateConfigChanged(); + instance()->IndicateConfigChanged(RsConfigMgr::CheckPriority::SAVE_NOW); RsServer::notify()->notifyListChange(NOTIFY_LIST_FRIENDS, accept ? NOTIFY_TYPE_ADD : NOTIFY_TYPE_DEL); diff --git a/src/pqi/p3peermgr.cc b/src/pqi/p3peermgr.cc index e150eae48..1933683f0 100644 --- a/src/pqi/p3peermgr.cc +++ b/src/pqi/p3peermgr.cc @@ -2101,6 +2101,7 @@ bool p3PeerMgrIMPL::setLocation(const RsPeerId &id, const std::string &locati mOwnState.location = location; changed = true; } + IndicateConfigChanged(RsConfigMgr::CheckPriority::SAVE_LESS); /**** INDICATE MSG CONFIG CHANGED! *****/ return changed; } @@ -2112,6 +2113,7 @@ bool p3PeerMgrIMPL::setLocation(const RsPeerId &id, const std::string &locati changed = true; } } + IndicateConfigChanged(RsConfigMgr::CheckPriority::SAVE_LESS); /**** INDICATE MSG CONFIG CHANGED! *****/ return changed; }