summaryrefslogtreecommitdiff
path: root/protocols/Tox/src/tox_events.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'protocols/Tox/src/tox_events.cpp')
-rw-r--r--protocols/Tox/src/tox_events.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/protocols/Tox/src/tox_events.cpp b/protocols/Tox/src/tox_events.cpp
index cef4bb7cc2..51d2421629 100644
--- a/protocols/Tox/src/tox_events.cpp
+++ b/protocols/Tox/src/tox_events.cpp
@@ -131,7 +131,7 @@ int CToxProto::OnSettingsChanged(MCONTACT hContact, LPARAM lParam)
DBCONTACTWRITESETTING* dbcws = (DBCONTACTWRITESETTING*)lParam;
if (hContact == NULL && !strcmp(dbcws->szModule, m_szModuleName) && !strcmp(dbcws->szSetting, "Nick"))
{
- if (tox_set_name(tox, (uint8_t*)(char*)ptrA(mir_utf8encodeW(dbcws->value.ptszVal)), _tcslen(dbcws->value.ptszVal)))
+ if (tox_set_name(tox, (uint8_t*)(char*)ptrA(mir_utf8encodeW(dbcws->value.ptszVal)), (uint16_t)_tcslen(dbcws->value.ptszVal)))
{
SaveToxData();
}
@@ -205,7 +205,7 @@ void CToxProto::OnStatusMessageChanged(Tox *tox, const int friendnumber, const u
void CToxProto::OnUserStatusChanged(Tox *tox, int32_t friendnumber, uint8_t usertatus, void *arg)
{
TOX_USERSTATUS userstatus = (TOX_USERSTATUS)usertatus;
- if (userstatus == TOX_USERSTATUS::TOX_USERSTATUS_NONE)
+ if (userstatus == TOX_USERSTATUS_NONE)
{
return;
}