summaryrefslogtreecommitdiff
path: root/protocols/Tox/src/tox_contacts.cpp
diff options
context:
space:
mode:
authorAlexander Lantsev <aunsane@gmail.com>2015-05-31 19:00:56 +0000
committerAlexander Lantsev <aunsane@gmail.com>2015-05-31 19:00:56 +0000
commite5d977a8e28a301ea56e2786756537d03b84540a (patch)
tree1a225e4ce7dcb3bfbb6a2aebd6c1b01ff5e73a45 /protocols/Tox/src/tox_contacts.cpp
parent6a08d8f762284e3ad8ddc2307287bef8a261989d (diff)
Tox: fixed contact adding
git-svn-id: http://svn.miranda-ng.org/main/trunk@13948 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'protocols/Tox/src/tox_contacts.cpp')
-rw-r--r--protocols/Tox/src/tox_contacts.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/protocols/Tox/src/tox_contacts.cpp b/protocols/Tox/src/tox_contacts.cpp
index 8441573384..abf80745de 100644
--- a/protocols/Tox/src/tox_contacts.cpp
+++ b/protocols/Tox/src/tox_contacts.cpp
@@ -63,7 +63,7 @@ MCONTACT CToxProto::GetContact(const char *pubKey)
return hContact;
}
-MCONTACT CToxProto::AddContact(const char *address, const TCHAR *nick, const TCHAR *dnsId, bool isTemporary)
+MCONTACT CToxProto::AddContact(const char *address, const char *nick, const char *dnsId, bool isTemporary)
{
MCONTACT hContact = GetContact(address);
if (!hContact)
@@ -73,11 +73,11 @@ MCONTACT CToxProto::AddContact(const char *address, const TCHAR *nick, const TCH
setString(hContact, TOX_SETTINGS_ID, address);
- if (mir_tstrlen(nick))
- setTString(hContact, "Nick", dnsId);
+ if (mir_strlen(nick))
+ setTString(hContact, "Nick", ptrT(mir_utf8decodeT(nick)));
- if (mir_tstrlen(dnsId))
- setTString(hContact, TOX_SETTINGS_DNS, dnsId);
+ if (mir_strlen(dnsId))
+ setTString(hContact, TOX_SETTINGS_DNS, ptrT(mir_utf8decodeT(dnsId)));
DBVARIANT dbv;
if (!getTString(TOX_SETTINGS_GROUP, &dbv))