summaryrefslogtreecommitdiff
path: root/protocols/Steam/src/steam_pooling.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'protocols/Steam/src/steam_pooling.cpp')
-rw-r--r--protocols/Steam/src/steam_pooling.cpp17
1 files changed, 9 insertions, 8 deletions
diff --git a/protocols/Steam/src/steam_pooling.cpp b/protocols/Steam/src/steam_pooling.cpp
index 826187c9a4..c6f7c3c747 100644
--- a/protocols/Steam/src/steam_pooling.cpp
+++ b/protocols/Steam/src/steam_pooling.cpp
@@ -198,16 +198,18 @@ void CSteamProto::ParsePollData(JSONNODE *data)
m_iStatus = m_iDesiredStatus = status;
ProtoBroadcastAck(NULL, ACKTYPE_STATUS, ACKRESULT_SUCCESS, (HANDLE)oldStatus, m_iStatus);
}
+
+ continue;
}
- else if(!FindContact(steamId))
- {
- MCONTACT hContact = AddContact(steamId);
+
+ MCONTACT hContact = FindContact(steamId);
+ if (hContact == NULL)
+ hContact = AddContact(steamId);
- setWord(hContact, "Status", status);
+ setWord(hContact, "Status", status);
- node = json_get(item, "persona_name");
- setWString(hContact, "Nick", json_as_string(node));
- }
+ node = json_get(item, "persona_name");
+ setWString(hContact, "Nick", json_as_string(node));
// todo: find difference between state changing and info changing
}
@@ -288,7 +290,6 @@ void CSteamProto::PollingThread(void*)
if (!lstrcmpi(error, L"OK"))
{
-
node = json_get(root, "messagelast");
messageId = json_as_int(node);