From 934c8f4a7acb9090b80d424b32fccd41abff9a0c Mon Sep 17 00:00:00 2001 From: George Hazan Date: Tue, 4 Dec 2018 14:43:57 +0300 Subject: more logs added for Jabber & Discord --- protocols/JabberG/src/jabber_proto.cpp | 4 ++-- protocols/JabberG/src/jabber_thread.cpp | 5 ++--- 2 files changed, 4 insertions(+), 5 deletions(-) (limited to 'protocols/JabberG/src') diff --git a/protocols/JabberG/src/jabber_proto.cpp b/protocols/JabberG/src/jabber_proto.cpp index 7a29dc6e91..68dde9068a 100755 --- a/protocols/JabberG/src/jabber_proto.cpp +++ b/protocols/JabberG/src/jabber_proto.cpp @@ -1110,12 +1110,12 @@ int CJabberProto::SetApparentMode(MCONTACT hContact, int mode) int CJabberProto::SetStatus(int iNewStatus) { + debugLogA("PS_SETSTATUS(%d,%d) => %d", m_iStatus, m_iDesiredStatus, iNewStatus); + if (m_iDesiredStatus == iNewStatus) return 0; int oldStatus = m_iStatus; - - debugLogA("PS_SETSTATUS(%d)", iNewStatus); m_iDesiredStatus = iNewStatus; if (iNewStatus == ID_STATUS_OFFLINE) { diff --git a/protocols/JabberG/src/jabber_thread.cpp b/protocols/JabberG/src/jabber_thread.cpp index dc24c999bc..b34f867053 100755 --- a/protocols/JabberG/src/jabber_thread.cpp +++ b/protocols/JabberG/src/jabber_thread.cpp @@ -263,6 +263,7 @@ void CJabberProto::ServerThread(JABBER_CONN_DATA *pParam) JLoginFailed(LOGINERR_BADUSERID); LBL_FatalError: + debugLogA("m_iDesiredStatus reset to (%d,%d) => %d", m_iStatus, m_iDesiredStatus, ID_STATUS_OFFLINE); int oldStatus = m_iStatus; m_iDesiredStatus = m_iStatus = ID_STATUS_OFFLINE; ProtoBroadcastAck(0, ACKTYPE_STATUS, ACKRESULT_SUCCESS, (HANDLE)oldStatus, m_iStatus); @@ -524,19 +525,17 @@ recvRest: WindowList_Broadcast(m_hWindowList, WM_JABBER_CHECK_ONLINE, 0, 0); // Set status to offline + debugLogA("m_iDesiredStatus reset to (%d,%d) => %d", m_iStatus, m_iDesiredStatus, ID_STATUS_OFFLINE); int oldStatus = m_iStatus; m_iDesiredStatus = m_iStatus = ID_STATUS_OFFLINE; ProtoBroadcastAck(0, ACKTYPE_STATUS, ACKRESULT_SUCCESS, (HANDLE)oldStatus, m_iStatus); - // Set all contacts to offline if (!m_StrmMgmt.IsResumeIdPresent()) { m_StrmMgmt.ResetState(); //fully reset strm_mgmt state -// debugLogA("1"); //i think this log calls does not needed anymore ? //sss for (auto &hContact : AccContacts()) SetContactOfflineStatus(hContact); -// debugLogA("2"); } mir_free(m_szJabberJID); -- cgit v1.2.3