diff options
author | Kirill Volinsky <mataes2007@gmail.com> | 2015-05-23 17:49:58 +0000 |
---|---|---|
committer | Kirill Volinsky <mataes2007@gmail.com> | 2015-05-23 17:49:58 +0000 |
commit | 6fcfba2c46a456677b5825a899469ba4e8905448 (patch) | |
tree | b4b6f6f9001b8609998a815ec1c7c92aa30b287e /protocols/Tlen/src/tlen_thread.cpp | |
parent | 24bed968f1e96aa4598d8dbe3a6e8a34dded3dc2 (diff) |
replace strncpy to mir_strncpy
git-svn-id: http://svn.miranda-ng.org/main/trunk@13785 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'protocols/Tlen/src/tlen_thread.cpp')
-rw-r--r-- | protocols/Tlen/src/tlen_thread.cpp | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/protocols/Tlen/src/tlen_thread.cpp b/protocols/Tlen/src/tlen_thread.cpp index f614b0a323..c8aef49d25 100644 --- a/protocols/Tlen/src/tlen_thread.cpp +++ b/protocols/Tlen/src/tlen_thread.cpp @@ -130,7 +130,7 @@ void __cdecl TlenServerThread(ThreadData *info) DBVARIANT dbv;
if (!db_get(NULL, info->proto->m_szModuleName, "LoginName", &dbv)) {
- strncpy(info->username, dbv.pszVal, sizeof(info->username));
+ mir_strncpy(info->username, dbv.pszVal, sizeof(info->username));
info->username[sizeof(info->username)-1] = '\0';
_strlwr(info->username);
db_set_s(NULL, info->proto->m_szModuleName, "LoginName", info->username);
@@ -143,7 +143,7 @@ void __cdecl TlenServerThread(ThreadData *info) if (loginErr == 0) {
if (!db_get(NULL, info->proto->m_szModuleName, "LoginServer", &dbv)) {
- strncpy(info->server, dbv.pszVal, sizeof(info->server));
+ mir_strncpy(info->server, dbv.pszVal, sizeof(info->server));
info->server[sizeof(info->server)-1] = '\0';
_strlwr(info->server);
db_set_s(NULL, info->proto->m_szModuleName, "LoginServer", info->server);
@@ -168,7 +168,7 @@ void __cdecl TlenServerThread(ThreadData *info) CloseHandle(hEventPasswdDlg);
if (onlinePassword[0] != (char) -1) {
- strncpy(info->password, onlinePassword, sizeof(info->password));
+ mir_strncpy(info->password, onlinePassword, sizeof(info->password));
info->password[sizeof(info->password)-1] = '\0';
}
else {
@@ -178,7 +178,7 @@ void __cdecl TlenServerThread(ThreadData *info) }
else {
if (!db_get(NULL, info->proto->m_szModuleName, "Password", &dbv)) {
- strncpy(info->password, dbv.pszVal, sizeof(info->password));
+ mir_strncpy(info->password, dbv.pszVal, sizeof(info->password));
info->password[sizeof(info->password)-1] = '\0';
db_free(&dbv);
}
@@ -211,7 +211,7 @@ void __cdecl TlenServerThread(ThreadData *info) db_set_s(NULL, info->proto->m_szModuleName, "jid", jidStr);
if (!db_get(NULL, info->proto->m_szModuleName, "ManualHost", &dbv)) {
- strncpy(info->manualHost, dbv.pszVal, sizeof(info->manualHost));
+ mir_strncpy(info->manualHost, dbv.pszVal, sizeof(info->manualHost));
info->manualHost[sizeof(info->manualHost)-1] = '\0';
db_free(&dbv);
}
@@ -227,7 +227,7 @@ void __cdecl TlenServerThread(ThreadData *info) if (!db_get(NULL, info->proto->m_szModuleName, "AvatarHash", &dbv)) {
- strncpy(info->proto->threadData->avatarHash, dbv.pszVal, sizeof(info->proto->threadData->avatarHash)-1);
+ mir_strncpy(info->proto->threadData->avatarHash, dbv.pszVal, sizeof(info->proto->threadData->avatarHash)-1);
db_free(&dbv);
}
info->avatarFormat = db_get_dw(NULL, info->proto->m_szModuleName, "AvatarFormat", PA_FORMAT_UNKNOWN);
@@ -587,7 +587,7 @@ static void TlenProcessAvatar(XmlNode* node, ThreadData *info) XmlNode *aNode = TlenXmlGetChild(node, "a");
if (tokenNode != NULL) {
char *token = tokenNode->text;
- strncpy(info->avatarToken, token, sizeof(info->avatarToken)-1);
+ mir_strncpy(info->avatarToken, token, sizeof(info->avatarToken)-1);
}
if (aNode != NULL) {
if (TlenProcessAvatarNode(info->proto, node, NULL)) {
|