summaryrefslogtreecommitdiff
path: root/src/modules/protocols
diff options
context:
space:
mode:
Diffstat (limited to 'src/modules/protocols')
-rw-r--r--src/modules/protocols/protoaccs.cpp2
-rw-r--r--src/modules/protocols/protocols.cpp2
-rw-r--r--src/modules/protocols/protoopts.cpp8
3 files changed, 6 insertions, 6 deletions
diff --git a/src/modules/protocols/protoaccs.cpp b/src/modules/protocols/protoaccs.cpp
index 4067068cad..7ffec4f215 100644
--- a/src/modules/protocols/protoaccs.cpp
+++ b/src/modules/protocols/protoaccs.cpp
@@ -373,7 +373,7 @@ static INT_PTR stub33(PROTO_INTERFACE* ppi, WPARAM wParam, LPARAM lParam)
static INT_PTR stub41(PROTO_INTERFACE* ppi, WPARAM wParam, LPARAM lParam)
{
- lstrcpynA((char*)lParam, ppi->m_szModuleName, wParam);
+ mir_strncpy((char*)lParam, ppi->m_szModuleName, wParam);
return 0;
}
diff --git a/src/modules/protocols/protocols.cpp b/src/modules/protocols/protocols.cpp
index 4cd162a278..ed8af42f0f 100644
--- a/src/modules/protocols/protocols.cpp
+++ b/src/modules/protocols/protocols.cpp
@@ -488,7 +488,7 @@ INT_PTR CallProtoServiceInt(MCONTACT hContact, const char *szModule, const char
return (INT_PTR)ppi->SetAwayMsg(wParam, StrConvT((char*)lParam));
return (INT_PTR)ppi->SetAwayMsg(wParam, (TCHAR*)lParam);
case 34: return (INT_PTR)ppi->UserIsTyping(wParam, lParam);
- case 35: lstrcpynA((char*)lParam, ppi->m_szModuleName, wParam); return 0;
+ case 35: mir_strncpy((char*)lParam, ppi->m_szModuleName, wParam); return 0;
case 36: return ppi->m_iStatus;
case 100:
diff --git a/src/modules/protocols/protoopts.cpp b/src/modules/protocols/protoopts.cpp
index 4b5c6eba6d..1024e945df 100644
--- a/src/modules/protocols/protoopts.cpp
+++ b/src/modules/protocols/protoopts.cpp
@@ -71,7 +71,7 @@ PROTOACCOUNT* Proto_CreateAccount(const char *szModuleName, const char *szBasePr
pa->szProtoName = mir_strdup(szBaseProto);
// if the internal name is empty, generate new one
- if (lstrlenA(szModuleName) == 0) {
+ if (mir_strlen(szModuleName) == 0) {
char buf[100];
int count = 1;
while (true) {
@@ -109,7 +109,7 @@ struct AccFormDlgParam
static bool FindAccountByName(const char *szModuleName)
{
- if (!lstrlenA(szModuleName))
+ if (!mir_strlen(szModuleName))
return false;
for (int i = 0; i < accounts.getCount(); i++)
@@ -620,7 +620,7 @@ INT_PTR CALLBACK AccMgrDlgProc(HWND hwndDlg, UINT message, WPARAM wParam, LPARAM
if (lps->itemID == (unsigned)dat->iSelected) {
SelectObject(lps->hDC, dat->hfntText);
mir_sntprintf(text, size, _T("%s: %S"), TranslateT("Protocol"), acc->szProtoName);
- length = lstrlen(text);
+ length = mir_tstrlen(text);
DrawText(lps->hDC, text, -1, &lps->rcItem, DT_LEFT | DT_NOPREFIX | DT_SINGLELINE | DT_END_ELLIPSIS);
GetTextExtentPoint32(lps->hDC, text, length, &sz);
lps->rcItem.top += sz.cy + 2;
@@ -653,7 +653,7 @@ INT_PTR CALLBACK AccMgrDlgProc(HWND hwndDlg, UINT message, WPARAM wParam, LPARAM
}
else mir_sntprintf(text, size, TranslateT("Protocol is not loaded."));
- length = lstrlen(text);
+ length = mir_tstrlen(text);
DrawText(lps->hDC, text, -1, &lps->rcItem, DT_LEFT | DT_NOPREFIX | DT_SINGLELINE | DT_END_ELLIPSIS);
GetTextExtentPoint32(lps->hDC, text, length, &sz);
lps->rcItem.top += sz.cy + 2;