diff options
author | Kirill Volinsky <mataes2007@gmail.com> | 2015-05-22 10:06:32 +0000 |
---|---|---|
committer | Kirill Volinsky <mataes2007@gmail.com> | 2015-05-22 10:06:32 +0000 |
commit | 5a17c9299e03bebf46169927abdeee34aaf8e854 (patch) | |
tree | cbd13080f33ac0b6396b9d3b8ba31a3c98de59f8 /plugins/SecureIM/src/splitmsg.cpp | |
parent | ed64312924e77707e7e5b5965c301692519f293a (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/SecureIM/src/splitmsg.cpp')
-rw-r--r-- | plugins/SecureIM/src/splitmsg.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/plugins/SecureIM/src/splitmsg.cpp b/plugins/SecureIM/src/splitmsg.cpp index 64e1577ad9..c58cfab9e3 100644 --- a/plugins/SecureIM/src/splitmsg.cpp +++ b/plugins/SecureIM/src/splitmsg.cpp @@ -5,7 +5,7 @@ LPSTR splitMsg(LPSTR szMsg, int iLen) {
Sent_NetLog("split: msg: -----\n%s\n-----\n", szMsg);
- size_t len = strlen(szMsg);
+ size_t len = mir_strlen(szMsg);
LPSTR out = (LPSTR)mir_alloc(len * 2);
LPSTR buf = out;
@@ -58,7 +58,7 @@ LPSTR combineMessage(pUinKey ptr, LPSTR szMsg) pm->message = new LPSTR[part_all];
memset(pm->message, 0, sizeof(LPSTR)*part_all);
}
- pm->message[part_num] = new char[strlen(szMsg)];
+ pm->message[part_num] = new char[mir_strlen(szMsg)];
strcpy(pm->message[part_num], szMsg + 8);
Sent_NetLog("combine: save part: %s", pm->message[part_num]);
@@ -66,7 +66,7 @@ LPSTR combineMessage(pUinKey ptr, LPSTR szMsg) int len = 0, i;
for (i = 0; i < part_all; i++) {
if (pm->message[i] == NULL) break;
- len += (int)strlen(pm->message[i]);
+ len += (int)mir_strlen(pm->message[i]);
}
if (i == part_all) { // combine message
SAFE_FREE(ptr->tmp);
@@ -93,14 +93,14 @@ LPSTR combineMessage(pUinKey ptr, LPSTR szMsg) // отправляет сообщение, если надо то разбивает на части
int splitMessageSend(pUinKey ptr, LPSTR szMsg)
{
- int len = (int)strlen(szMsg);
+ int len = (int)mir_strlen(szMsg);
int par = (getContactStatus(ptr->hContact) == ID_STATUS_OFFLINE) ? ptr->proto->split_off : ptr->proto->split_on;
if (par && len > par) {
int ret;
LPSTR msg = splitMsg(szMsg, par);
LPSTR buf = msg;
while (*buf) {
- len = (int)strlen(buf);
+ len = (int)mir_strlen(buf);
LPSTR tmp = mir_strdup(buf);
ret = CallContactService(ptr->hContact, PSS_MESSAGE, (WPARAM)PREF_METANODB, (LPARAM)tmp);
mir_free(tmp);
|