diff options
author | Kirill Volinsky <mataes2007@gmail.com> | 2013-02-24 16:04:55 +0000 |
---|---|---|
committer | Kirill Volinsky <mataes2007@gmail.com> | 2013-02-24 16:04:55 +0000 |
commit | 83f05d582cdb837cef1b2c103ebb1e2a00568371 (patch) | |
tree | b5b40d269f65e52efe432e6e913c5d6b8a06276a /protocols/Skype/src/skype_account.cpp | |
parent | 4330f80c5e76c7cbc277ff27e57d3abc308bc915 (diff) |
fixes crashes for work with last proto changes
git-svn-id: http://svn.miranda-ng.org/main/trunk@3756 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'protocols/Skype/src/skype_account.cpp')
-rw-r--r-- | protocols/Skype/src/skype_account.cpp | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/protocols/Skype/src/skype_account.cpp b/protocols/Skype/src/skype_account.cpp index 6002061a6f..e4e2887481 100644 --- a/protocols/Skype/src/skype_account.cpp +++ b/protocols/Skype/src/skype_account.cpp @@ -32,8 +32,11 @@ void CSkypeProto::OnAccountChanged(int prop) if (this->rememberPassword && whyLogout == CAccount::INCORRECT_PASSWORD)
{
this->rememberPassword = false;
- if (this->password)
+ if (this->password)
+ {
::mir_free(this->password);
+ this->password = NULL;
+ }
}
}
}
@@ -81,7 +84,10 @@ bool CSkypeProto::IsOnline() void __cdecl CSkypeProto::SignInAsync(void*)
{
if ( !this->rememberPassword)
+ {
::mir_free(this->password);
+ this->password = NULL;
+ }
else
{
::CallService(MS_DB_CRYPT_ENCODESTRING, ::strlen(this->password), LPARAM(this->password));
@@ -109,12 +115,18 @@ bool CSkypeProto::SignIn(int status) if ( !this->rememberPassword)
{
if (this->password)
+ {
::mir_free(this->password);
+ this->password = NULL;
+ }
this->password = ::DBGetString(NULL, this->m_szModuleName, SKYPE_SETTINGS_PASSWORD);
if ( !this->password || !::strlen(this->password))
{
if (this->password)
+ {
::mir_free(this->password);
+ this->password = NULL;
+ }
PasswordRequestBoxParam param(this->login);
if ( !this->RequestPassword(param))
{
|