summaryrefslogtreecommitdiff
path: root/plugins/Clist_nicer/src/extBackg.cpp
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2015-05-28 15:44:18 +0000
committerGeorge Hazan <george.hazan@gmail.com>2015-05-28 15:44:18 +0000
commit4fa9a8b4f873f5a97c74c3cac6fc1384b9b22f17 (patch)
tree10148c3460d43042feecba4cf1ec02958e3c4d24 /plugins/Clist_nicer/src/extBackg.cpp
parentec112925e1c1419182451cc2f0f6e985d9ddb1de (diff)
unsafe strncat removed
git-svn-id: http://svn.miranda-ng.org/main/trunk@13876 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/Clist_nicer/src/extBackg.cpp')
-rw-r--r--plugins/Clist_nicer/src/extBackg.cpp9
1 files changed, 4 insertions, 5 deletions
diff --git a/plugins/Clist_nicer/src/extBackg.cpp b/plugins/Clist_nicer/src/extBackg.cpp
index bf285973c1..4e441c8c98 100644
--- a/plugins/Clist_nicer/src/extBackg.cpp
+++ b/plugins/Clist_nicer/src/extBackg.cpp
@@ -288,11 +288,10 @@ void LoadExtBkSettingsFromDB()
ID_EXTBK_LAST++;
mir_snprintf(p->szDBname, SIZEOF(p->szDBname), "EXBK_%s", accs[i]->szModuleName);
- if (i == 0) {
- mir_strncpy(p->szName, "{-}", SIZEOF(p->szName));
- mir_strncat(p->szName, accs[i]->szModuleName, SIZEOF(p->szName) - mir_strlen(p->szName));
- }
- else mir_strncpy(p->szName, accs[i]->szModuleName, SIZEOF(p->szName));
+ if (i == 0)
+ mir_snprintf(p->szName, SIZEOF(p->szName), "{-}%s", accs[i]->szModuleName);
+ else
+ strncpy_s(p->szName, accs[i]->szModuleName, _TRUNCATE);
p->statusID = ID_EXTBK_LAST;
arStatusItems.insert(p);
}