From 5aed15a8d8d8e4f913539761be496e0d1ba2c4f0 Mon Sep 17 00:00:00 2001 From: Kirill Volinsky Date: Sun, 24 May 2015 12:20:50 +0000 Subject: replace wcslen to mir_wstrlen git-svn-id: http://svn.miranda-ng.org/main/trunk@13813 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c --- plugins/UserInfoEx/src/commonheaders.cpp | 4 ++-- plugins/UserInfoEx/src/mir_string.cpp | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) (limited to 'plugins/UserInfoEx') diff --git a/plugins/UserInfoEx/src/commonheaders.cpp b/plugins/UserInfoEx/src/commonheaders.cpp index 3d4942e84f..8eb7699f3a 100644 --- a/plugins/UserInfoEx/src/commonheaders.cpp +++ b/plugins/UserInfoEx/src/commonheaders.cpp @@ -136,7 +136,7 @@ unsigned int __fastcall hash_M2(const void * key, unsigned int len) unsigned int hashSettingW_M2(const char * key) { if (key == NULL) return 0; - const unsigned int len = (unsigned int)wcslen((const wchar_t*)key); + const unsigned int len = (unsigned int)mir_wstrlen((const wchar_t*)key); char* buf = (char*)alloca(len + 1); for (unsigned i = 0; i <= len ; ++i) buf[i] = key[i << 1]; @@ -153,7 +153,7 @@ unsigned int hashSetting_M2(const char * key) unsigned int hashSetting_M2(const wchar_t * key) { if (key == NULL) return 0; - const unsigned int len = (unsigned int)wcslen((const wchar_t*)key); + const unsigned int len = (unsigned int)mir_wstrlen((const wchar_t*)key); return hash_M2(key, len * sizeof(wchar_t)); } diff --git a/plugins/UserInfoEx/src/mir_string.cpp b/plugins/UserInfoEx/src/mir_string.cpp index d68ba2cb07..a454bbdc9d 100644 --- a/plugins/UserInfoEx/src/mir_string.cpp +++ b/plugins/UserInfoEx/src/mir_string.cpp @@ -40,7 +40,7 @@ wchar_t* mir_wcsncat_c(wchar_t *pwszDest, const wchar_t wcSrc) { size_t size = 2; if (pwszDest != NULL) - size += wcslen(pwszDest); //cSrc = 1 + 1 forNULL temination + size += mir_wstrlen(pwszDest); //cSrc = 1 + 1 forNULL temination wchar_t *pwszRet = (wchar_t *)mir_realloc(pwszDest, (sizeof(wchar_t) * size)); if (pwszRet == NULL) -- cgit v1.2.3