summaryrefslogtreecommitdiff
path: root/protocols/JabberG/src/jabber_thread.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'protocols/JabberG/src/jabber_thread.cpp')
-rw-r--r--protocols/JabberG/src/jabber_thread.cpp7
1 files changed, 2 insertions, 5 deletions
diff --git a/protocols/JabberG/src/jabber_thread.cpp b/protocols/JabberG/src/jabber_thread.cpp
index 908628ae77..eb8d34d2c9 100644
--- a/protocols/JabberG/src/jabber_thread.cpp
+++ b/protocols/JabberG/src/jabber_thread.cpp
@@ -153,12 +153,9 @@ void CJabberProto::CheckKeepAlive()
// unfortunately there's no other way to detect if that message came online or from history
time_t now = time(0);
LISTFOREACH(i, this, LIST_CHATROOM)
- {
if (auto *item = ListGetItemPtrFromIndex(i))
if (!item->bChatLogging && now - item->iChatInitTime > 2)
item->bChatLogging = true;
- }
-
// check expired iq requests
m_iqManager.CheckExpired();
@@ -269,7 +266,7 @@ void CJabberProto::ServerThread(JABBER_CONN_DATA *pParam)
// quit all chatrooms (will send quit message)
LISTFOREACH(i, this, LIST_CHATROOM)
- if (JABBER_LIST_ITEM *item = ListGetItemPtrFromIndex(i))
+ if (auto *item = ListGetItemPtrFromIndex(i))
GcQuit(item, 0, nullptr);
ListRemoveList(LIST_CHATROOM);
@@ -1958,7 +1955,7 @@ void CJabberProto::OnProcessIq(const TiXmlElement *node)
// Check for file transfer deny by comparing idStr with ft->iqId
LISTFOREACH(i, this, LIST_FILE)
{
- JABBER_LIST_ITEM *item = ListGetItemPtrFromIndex(i);
+ auto *item = ListGetItemPtrFromIndex(i);
if (item->ft != nullptr && item->ft->state == FT_CONNECTING && !mir_strcmp(tszBuf, item->ft->szId)) {
debugLogA("Denying file sending request");
item->ft->state = FT_DENIED;