summaryrefslogtreecommitdiff
path: root/plugins/Variables/src/parse_inet.cpp
diff options
context:
space:
mode:
authorKirill Volinsky <mataes2007@gmail.com>2015-05-22 10:06:32 +0000
committerKirill Volinsky <mataes2007@gmail.com>2015-05-22 10:06:32 +0000
commit5a17c9299e03bebf46169927abdeee34aaf8e854 (patch)
treecbd13080f33ac0b6396b9d3b8ba31a3c98de59f8 /plugins/Variables/src/parse_inet.cpp
parented64312924e77707e7e5b5965c301692519f293a (diff)
replace strlen to mir_strlen
git-svn-id: http://svn.miranda-ng.org/main/trunk@13747 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/Variables/src/parse_inet.cpp')
-rw-r--r--plugins/Variables/src/parse_inet.cpp18
1 files changed, 9 insertions, 9 deletions
diff --git a/plugins/Variables/src/parse_inet.cpp b/plugins/Variables/src/parse_inet.cpp
index 4843b6557f..c1c6f405ac 100644
--- a/plugins/Variables/src/parse_inet.cpp
+++ b/plugins/Variables/src/parse_inet.cpp
@@ -29,20 +29,20 @@ static TCHAR *parseUrlEnc(ARGUMENTSINFO *ai)
return NULL;
size_t cur = 0;
- while (cur < strlen(res)) {
+ while (cur < mir_strlen(res)) {
if (((*(res + cur) >= '0') && (*(res + cur) <= '9')) || ((*(res + cur) >= 'a') && (*(res + cur) <= 'z')) || ((*(res + cur) >= 'A') && (*(res + cur) <= 'Z'))) {
cur++;
continue;
}
- res = (char*)mir_realloc(res, strlen(res) + 4);
+ res = (char*)mir_realloc(res, mir_strlen(res) + 4);
if (res == NULL)
return NULL;
char hex[8];
- memmove(res + cur + 3, res + cur + 1, strlen(res + cur + 1) + 1);
+ memmove(res + cur + 3, res + cur + 1, mir_strlen(res + cur + 1) + 1);
mir_snprintf(hex, SIZEOF(hex), "%%%x", *(res + cur));
- strncpy(res + cur, hex, strlen(hex));
- cur += strlen(hex);
+ strncpy(res + cur, hex, mir_strlen(hex));
+ cur += mir_strlen(hex);
}
TCHAR *tres = mir_a2t(res);
@@ -60,18 +60,18 @@ static TCHAR *parseUrlDec(ARGUMENTSINFO *ai)
return NULL;
unsigned int cur = 0;
- while (cur < strlen(res)) {
- if ((*(res + cur) == '%') && (strlen(res + cur) >= 3)) {
+ while (cur < mir_strlen(res)) {
+ if ((*(res + cur) == '%') && (mir_strlen(res + cur) >= 3)) {
char hex[8];
memset(hex, '\0', sizeof(hex));
strncpy(hex, res + cur + 1, 2);
*(res + cur) = (char)strtol(hex, NULL, 16);
- memmove(res + cur + 1, res + cur + 3, strlen(res + cur + 3) + 1);
+ memmove(res + cur + 1, res + cur + 3, mir_strlen(res + cur + 3) + 1);
}
cur++;
}
- res = (char*)mir_realloc(res, strlen(res) + 1);
+ res = (char*)mir_realloc(res, mir_strlen(res) + 1);
TCHAR *tres = mir_a2t(res);
mir_free(res);
return tres;