From c45fb2f2debca153f2008c4bd6789a25eaabfe60 Mon Sep 17 00:00:00 2001 From: George Hazan Date: Fri, 11 Sep 2020 17:21:39 +0300 Subject: Steam: if a friend list request comes with error code, all contacts are removed from Miranda --- protocols/Steam/src/steam_contacts.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/protocols/Steam/src/steam_contacts.cpp b/protocols/Steam/src/steam_contacts.cpp index a52d2ed3a7..2f20ba9378 100644 --- a/protocols/Steam/src/steam_contacts.cpp +++ b/protocols/Steam/src/steam_contacts.cpp @@ -395,6 +395,11 @@ void CSteamProto::OnGotFriendList(const JSONNode &root, void *) json_string steamId = _friend["steamid"].as_string(); friendsMap.insert(std::make_pair(steamId, &_friend)); } + + if (friendsMap.empty()) { + debugLogA("Empty friends list, exiting"); + return; + } // Check and update contacts in database for (auto &hContact : AccContacts()) { -- cgit v1.2.3