summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorKirill Volinsky <mataes2007@gmail.com>2015-05-24 12:20:50 +0000
committerKirill Volinsky <mataes2007@gmail.com>2015-05-24 12:20:50 +0000
commit5aed15a8d8d8e4f913539761be496e0d1ba2c4f0 (patch)
treedd9996ff223dc09154ed3c65d51ce528a9b2f81d /src
parent2cd063aa25c633f2bf4213e007bf2df5d610d8e1 (diff)
replace wcslen to mir_wstrlen
git-svn-id: http://svn.miranda-ng.org/main/trunk@13813 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'src')
-rw-r--r--src/modules/clist/contacts.cpp4
-rw-r--r--src/modules/xml/xmlParser.cpp4
2 files changed, 4 insertions, 4 deletions
diff --git a/src/modules/clist/contacts.cpp b/src/modules/clist/contacts.cpp
index 86062285f7..d6dc9d044d 100644
--- a/src/modules/clist/contacts.cpp
+++ b/src/modules/clist/contacts.cpp
@@ -184,7 +184,7 @@ static INT_PTR GetContactInfo(WPARAM, LPARAM lParam)
if (!GetDatabaseString(ci, "LastName", &dbv2)) {
ci->type = CNFT_ASCIIZ;
if (ci->dwFlag & CNF_UNICODE) {
- size_t len = wcslen(dbv.pwszVal) + wcslen(dbv2.pwszVal) + 2;
+ size_t len = mir_wstrlen(dbv.pwszVal) + mir_wstrlen(dbv2.pwszVal) + 2;
WCHAR* buf = (WCHAR*)mir_alloc(sizeof(WCHAR)*len);
if (buf != NULL)
wcscat(wcscat(wcscpy(buf, dbv.pwszVal), L" "), dbv2.pwszVal);
@@ -309,7 +309,7 @@ static INT_PTR GetContactInfo(WPARAM, LPARAM lParam)
ci->type = CNFT_ASCIIZ;
if (ci->dwFlag & CNF_UNICODE) {
- size_t len = wcslen(dbv.pwszVal) + wcslen(dbv2.pwszVal) + 2;
+ size_t len = mir_wstrlen(dbv.pwszVal) + mir_wstrlen(dbv2.pwszVal) + 2;
WCHAR* buf = (WCHAR*)mir_alloc(sizeof(WCHAR)*len);
if (buf != NULL)
wcscat(wcscat(wcscpy(buf, dbv.pwszVal), L" "), dbv2.pwszVal);
diff --git a/src/modules/xml/xmlParser.cpp b/src/modules/xml/xmlParser.cpp
index 79eb1fc6e1..885d6d81c1 100644
--- a/src/modules/xml/xmlParser.cpp
+++ b/src/modules/xml/xmlParser.cpp
@@ -202,7 +202,7 @@ wchar_t *myMultiByteToWideChar(const char *s, XMLNode::XMLCharEncoding ce)
return d;
}
static inline FILE *xfopen(XMLCSTR filename, XMLCSTR mode) { return _wfopen(filename, mode); }
-static inline size_t xstrlen(XMLCSTR c) { return wcslen(c); }
+static inline size_t xstrlen(XMLCSTR c) { return mir_wstrlen(c); }
static inline int xstrnicmp(XMLCSTR c1, XMLCSTR c2, int l) { return _wcsnicmp(c1, c2, l);}
static inline int xstrncmp(XMLCSTR c1, XMLCSTR c2, int l) { return wcsncmp(c1, c2, l);}
static inline int xstricmp(XMLCSTR c1, XMLCSTR c2) { return _wcsicmp(c1, c2); }
@@ -275,7 +275,7 @@ wchar_t *myMultiByteToWideChar(const char *s, XMLNode::XMLCharEncoding ce)
d[i] = 0;
return d;
}
-int xstrlen(XMLCSTR c) { return wcslen(c); }
+int xstrlen(XMLCSTR c) { return mir_wstrlen(c); }
#ifdef sun
// for CC
#include <widec.h>