From 2296a0167f5f3f2c51e02bf9201e8b50fb67bd76 Mon Sep 17 00:00:00 2001 From: George Hazan Date: Tue, 14 Mar 2023 14:37:39 +0300 Subject: =?UTF-8?q?fixes=20#3427=20(ICQ:=20=D1=83=20=D0=B3=D1=80=D1=83?= =?UTF-8?q?=D0=BF=D1=87=D0=B0=D1=82=D0=BE=D0=B2=20=D1=82=D0=B5=D0=BF=D0=B5?= =?UTF-8?q?=D1=80=D1=8C=20ID=20=D0=B2=D0=BC=D0=B5=D1=81=D1=82=D0=BE=20?= =?UTF-8?q?=D0=B8=D0=BC=D0=B5=D0=BD=D0=B8)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- protocols/ICQ-WIM/src/poll.cpp | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) (limited to 'protocols/ICQ-WIM/src') diff --git a/protocols/ICQ-WIM/src/poll.cpp b/protocols/ICQ-WIM/src/poll.cpp index fe344a8ccc..9b1e5aae92 100644 --- a/protocols/ICQ-WIM/src/poll.cpp +++ b/protocols/ICQ-WIM/src/poll.cpp @@ -168,9 +168,17 @@ void CIcqProto::ProcessHistData(const JSONNode &ev) if (IsChat(wszId)) { SESSION_INFO *si = Chat_Find(wszId, m_szModuleName); - if (si == nullptr) - if ((si = CreateGroupChat(wszId, L"")) == nullptr) + if (si == nullptr) { + CMStringW wszNick; + for (auto &it : ev["persons"]) + if (it["sn"].as_mstring() == wszId) { + wszNick = it["friendly"].as_mstring(); + break; + } + + if ((si = CreateGroupChat(wszId, wszNick)) == nullptr) return; + } hContact = si->hContact; -- cgit v1.2.3