summaryrefslogtreecommitdiff
path: root/protocols/Tox
diff options
context:
space:
mode:
authorAlexander Lantsev <aunsane@gmail.com>2014-08-23 20:45:50 +0000
committerAlexander Lantsev <aunsane@gmail.com>2014-08-23 20:45:50 +0000
commit1147413314adde0812d1b94fb10a6da2a7ec7514 (patch)
treee55b653bf351a1c3f8a7667b7de4ba3f543bc7e0 /protocols/Tox
parentdf1139ff3c50f0cffc7dc7a8a4e7310eb7e55e2d (diff)
Tox: fixed contact discovering
git-svn-id: http://svn.miranda-ng.org/main/trunk@10316 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'protocols/Tox')
-rw-r--r--protocols/Tox/src/tox_contacts.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/protocols/Tox/src/tox_contacts.cpp b/protocols/Tox/src/tox_contacts.cpp
index 0806bc7b24..515aa13b3b 100644
--- a/protocols/Tox/src/tox_contacts.cpp
+++ b/protocols/Tox/src/tox_contacts.cpp
@@ -61,7 +61,7 @@ MCONTACT CToxProto::FindContact(const std::string &id)
for (hContact = db_find_first(m_szModuleName); hContact; hContact = db_find_next(hContact, m_szModuleName))
{
std::string contactId = ToxAddressToId(getStringA(hContact, TOX_SETTINGS_ID));
- if (id.compare(contactId))
+ if (id.compare(contactId) == 0)
{
break;
}
@@ -121,7 +121,7 @@ void CToxProto::LoadContactList()
tox_get_client_id(tox, friends[i], &clientId[0]);
std::string id = DataToHexString(clientId);
- MCONTACT hContact = AddContact(id.c_str());
+ MCONTACT hContact = AddContact(id);
if (hContact)
{
int size = tox_get_name_size(tox, friends[i]);