summaryrefslogtreecommitdiff
path: root/plugins/Non-IM Contact/src/dialog.cpp
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2015-05-28 15:42:01 +0000
committerGeorge Hazan <george.hazan@gmail.com>2015-05-28 15:42:01 +0000
commitdbea29eeae016a4a48b91b954f3a4e93ca4072f7 (patch)
tree850a1ba65195fa3900143bfba4ae3c2b3855ea5d /plugins/Non-IM Contact/src/dialog.cpp
parent70aa67d368abc8ba2b9a03213bad7be1fcad40bf (diff)
unsafe strncat removed
git-svn-id: http://svn.miranda-ng.org/main/trunk@13872 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/Non-IM Contact/src/dialog.cpp')
-rw-r--r--plugins/Non-IM Contact/src/dialog.cpp9
1 files changed, 5 insertions, 4 deletions
diff --git a/plugins/Non-IM Contact/src/dialog.cpp b/plugins/Non-IM Contact/src/dialog.cpp
index 9e6fb07c4d..1e85c207a5 100644
--- a/plugins/Non-IM Contact/src/dialog.cpp
+++ b/plugins/Non-IM Contact/src/dialog.cpp
@@ -175,21 +175,22 @@ INT_PTR CALLBACK TestWindowDlgProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lP
break;
case IDOK:
- char str2replace[MAX_STRING_LENGTH], replacedString[MAX_STRING_LENGTH];
+ CMStringA replacedString;
+ char str2replace[MAX_STRING_LENGTH];
int error;
if (GetWindowTextLength(GetDlgItem(hwnd, IDC_STRING))) {
GetDlgItemTextA(hwnd, IDC_STRING, str2replace, SIZEOF(str2replace));
switch (stringReplacer(str2replace, replacedString, NULL)) {
case ERROR_NO_LINE_AFTER_VAR_F:
- mir_snprintf(replacedString, SIZEOF(replacedString), "ERROR: no %s", "%line or %wholeline or %lastline after %fn");
+ replacedString.Format("ERROR: no %s", "%line or %wholeline or %lastline after %fn");
error = 1;
break;
case ERROR_LINE_NOT_READ:
- mir_snprintf(replacedString, SIZEOF(replacedString), "ERROR: file couldnt be opened ");
+ replacedString.Format("ERROR: file couldnt be opened ");
error = 1;
break;
case ERROR_NO_FILE:
- mir_snprintf(replacedString, SIZEOF(replacedString), "ERROR: no file specified in settings");
+ replacedString.Format("ERROR: no file specified in settings");
error = 1;
break;
default: