From 76403b8fa94edb904ddf9a6b5426b193062e08bf Mon Sep 17 00:00:00 2001 From: MikalaiR Date: Fri, 2 Oct 2015 16:13:06 +0000 Subject: WhatsApp: memleaks fix git-svn-id: http://svn.miranda-ng.org/main/trunk@15489 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c --- protocols/WhatsApp/src/WhatsAPI++/BinTreeNodeReader.cpp | 1 + protocols/WhatsApp/src/chat.cpp | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) (limited to 'protocols') diff --git a/protocols/WhatsApp/src/WhatsAPI++/BinTreeNodeReader.cpp b/protocols/WhatsApp/src/WhatsAPI++/BinTreeNodeReader.cpp index daf17108a8..0dfa824738 100644 --- a/protocols/WhatsApp/src/WhatsAPI++/BinTreeNodeReader.cpp +++ b/protocols/WhatsApp/src/WhatsAPI++/BinTreeNodeReader.cpp @@ -159,6 +159,7 @@ ReadData* BinTreeNodeReader::readString(int token) switch (token) { case 0: + delete ret; return NULL; case 252: diff --git a/protocols/WhatsApp/src/chat.cpp b/protocols/WhatsApp/src/chat.cpp index 32e3a07a40..7213760549 100644 --- a/protocols/WhatsApp/src/chat.cpp +++ b/protocols/WhatsApp/src/chat.cpp @@ -207,7 +207,7 @@ void WhatsAppProto::NickListMenuHook(WAChatInfo *pInfo, struct GCHOOK *gch) break; case IDM_CPY_NICK: - utils::copyText(pcli->hwndContactList, GetChatUserNick(std::string((char*)_T2A(gch->ptszUID)))); + utils::copyText(pcli->hwndContactList, ptrT(GetChatUserNick(std::string((char*)_T2A(gch->ptszUID))))); break; case IDM_CPY_RJID: -- cgit v1.2.3