From 27d17244cb0af6f8b04e2b6725d504c336dabb07 Mon Sep 17 00:00:00 2001 From: George Hazan Date: Mon, 6 May 2013 15:42:54 +0000 Subject: memory leaks git-svn-id: http://svn.miranda-ng.org/main/trunk@4592 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c --- protocols/Skype/src/skype_proto.cpp | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) (limited to 'protocols/Skype/src/skype_proto.cpp') diff --git a/protocols/Skype/src/skype_proto.cpp b/protocols/Skype/src/skype_proto.cpp index e0e7f1b74e..d320f51b84 100644 --- a/protocols/Skype/src/skype_proto.cpp +++ b/protocols/Skype/src/skype_proto.cpp @@ -125,7 +125,7 @@ int __cdecl CSkypeProto::AuthRequest(HANDLE hContact, const TCHAR* szMessage) if (this->IsOnline() && hContact) { CContact::Ref contact; - SEString sid(::mir_u2a(::db_get_wsa(hContact, this->m_szModuleName, SKYPE_SETTINGS_LOGIN))); + SEString sid( mir_ptr(::mir_u2a( mir_ptr(::db_get_wsa(hContact, this->m_szModuleName, SKYPE_SETTINGS_LOGIN))))); if (g_skype->GetContact(sid, contact)) { contact->SetBuddyStatus(Contact::AUTHORIZED_BY_ME); @@ -353,7 +353,7 @@ HANDLE __cdecl CSkypeProto::SendFile(HANDLE hContact, const TCHAR *szDescription int __cdecl CSkypeProto::SendMsg(HANDLE hContact, int flags, const char *msg) { SEStringList targets; - wchar_t *sid = ::db_get_wsa(hContact, this->m_szModuleName, SKYPE_SETTINGS_LOGIN); + mir_ptr sid( ::db_get_wsa(hContact, this->m_szModuleName, SKYPE_SETTINGS_LOGIN)); SEString identity = ::mir_u2a(sid); targets.append(identity); @@ -421,7 +421,7 @@ int __cdecl CSkypeProto::UserIsTyping(HANDLE hContact, int type) { if (hContact && this->IsOnline() && this->m_iStatus != ID_STATUS_INVISIBLE) { - wchar_t *sid = ::db_get_wsa(hContact, this->m_szModuleName, SKYPE_SETTINGS_LOGIN); + mir_ptr sid( ::db_get_wsa(hContact, this->m_szModuleName, SKYPE_SETTINGS_LOGIN)); if (::wcsicmp(sid, this->login) != 0) { SEStringList targets; @@ -444,7 +444,6 @@ int __cdecl CSkypeProto::UserIsTyping(HANDLE hContact, int type) } } } - ::mir_free(sid); } return 1; -- cgit v1.2.3