summaryrefslogtreecommitdiff
path: root/protocols/Tox/src/tox_account.cpp
diff options
context:
space:
mode:
authorAlexander Lantsev <aunsane@gmail.com>2014-08-17 18:57:11 +0000
committerAlexander Lantsev <aunsane@gmail.com>2014-08-17 18:57:11 +0000
commit9242cbc94746fc871e71c20b6977e1bb2cfe9c3e (patch)
tree829731785ed03a9a8bf4e55a34828e0ae3edd2d2 /protocols/Tox/src/tox_account.cpp
parentae4baba8780a843d17e3403a618775f31f9df7f9 (diff)
Tox:
- fixed friend names - some fixes with profile changing git-svn-id: http://svn.miranda-ng.org/main/trunk@10217 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'protocols/Tox/src/tox_account.cpp')
-rw-r--r--protocols/Tox/src/tox_account.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/protocols/Tox/src/tox_account.cpp b/protocols/Tox/src/tox_account.cpp
index b4871425d2..f78f8b24a2 100644
--- a/protocols/Tox/src/tox_account.cpp
+++ b/protocols/Tox/src/tox_account.cpp
@@ -41,10 +41,11 @@ void CToxProto::InitToxCore()
LoadToxData();
- std::vector<uint8_t> username(TOX_MAX_NAME_LENGTH);
+ int size = tox_get_self_name_size(tox);
+ std::vector<uint8_t> username(size);
tox_get_self_name(tox, &username[0]);
std::string nick(username.begin(), username.end());
- setString("Nick", nick.c_str());
+ setWString("Nick", ptrW(Utf8DecodeW(nick.c_str())));
}
void CToxProto::UninitToxCore()