From ddbeef14631c4232cbd0e9e8d04dcc217cfe5fe6 Mon Sep 17 00:00:00 2001 From: George Hazan Date: Fri, 26 Apr 2013 20:37:41 +0000 Subject: more correct version of SetStatus git-svn-id: http://svn.miranda-ng.org/main/trunk@4541 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c --- protocols/Skype/src/skype_proto.cpp | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) (limited to 'protocols/Skype/src') diff --git a/protocols/Skype/src/skype_proto.cpp b/protocols/Skype/src/skype_proto.cpp index faf7a980e0..52f976e934 100644 --- a/protocols/Skype/src/skype_proto.cpp +++ b/protocols/Skype/src/skype_proto.cpp @@ -385,7 +385,6 @@ int CSkypeProto::SetStatus(int new_status) { this->LogOut(); this->m_iStatus = this->m_iDesiredStatus = ID_STATUS_OFFLINE; - this->SendBroadcast(NULL, ACKTYPE_STATUS, ACKRESULT_SUCCESS, (HANDLE)old_status, m_iStatus); } else { @@ -397,13 +396,16 @@ int CSkypeProto::SetStatus(int new_status) } else { - if ( this->account->IsOnline()) + if ( this->account->IsOnline()) { SetServerStatus(new_status); - else - SendBroadcast(NULL, ACKTYPE_STATUS, ACKRESULT_SUCCESS, (HANDLE)old_status, m_iStatus); + return 0; + } + + SendBroadcast(NULL, ACKTYPE_STATUS, ACKRESULT_SUCCESS, (HANDLE)old_status, m_iStatus); } } + this->SendBroadcast(NULL, ACKTYPE_STATUS, ACKRESULT_SUCCESS, (HANDLE)old_status, m_iStatus); return 0; } -- cgit v1.2.3