summaryrefslogtreecommitdiff
path: root/plugins/New_GPG/src
diff options
context:
space:
mode:
authorRozhuk Ivan <rozhuk.im@gmail.com>2014-12-09 00:59:27 +0000
committerRozhuk Ivan <rozhuk.im@gmail.com>2014-12-09 00:59:27 +0000
commit36472b00443e23acf28b0dd26ddc2c2e6216d909 (patch)
treea526bbc6d309e05f1728b772620c9272f9ab8c4a /plugins/New_GPG/src
parent163ce5127e5c8244bccbdae72107ad101f70575f (diff)
code cleanup over mir_sntprintf + small bug fix
git-svn-id: http://svn.miranda-ng.org/main/trunk@11295 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/New_GPG/src')
-rwxr-xr-xplugins/New_GPG/src/main.cpp4
-rwxr-xr-xplugins/New_GPG/src/options.cpp6
-rwxr-xr-xplugins/New_GPG/src/utilities.cpp10
3 files changed, 10 insertions, 10 deletions
diff --git a/plugins/New_GPG/src/main.cpp b/plugins/New_GPG/src/main.cpp
index 9d09305217..886732df7b 100755
--- a/plugins/New_GPG/src/main.cpp
+++ b/plugins/New_GPG/src/main.cpp
@@ -706,7 +706,7 @@ static INT_PTR CALLBACK DlgProcFirstRun(HWND hwndDlg,UINT msg,WPARAM wParam,LPAR
if(!szKey)
{
TCHAR msg[64];
- mir_sntprintf(msg, 64, TranslateT("Failed to lock memory with error %d"), GetLastError());
+ mir_sntprintf(msg, SIZEOF(msg), TranslateT("Failed to lock memory with error %d"), GetLastError());
MessageBox(0, msg, TranslateT("Error"), MB_OK);
GlobalFree(hMem);
}
@@ -718,7 +718,7 @@ static INT_PTR CALLBACK DlgProcFirstRun(HWND hwndDlg,UINT msg,WPARAM wParam,LPAR
{
GlobalFree(hMem);
TCHAR msg[64];
- mir_sntprintf(msg, 64, TranslateT("Failed write to clipboard with error %d"), GetLastError());
+ mir_sntprintf(msg, SIZEOF(msg), TranslateT("Failed write to clipboard with error %d"), GetLastError());
MessageBox(0, msg, TranslateT("Error"), MB_OK);
}
CloseClipboard();
diff --git a/plugins/New_GPG/src/options.cpp b/plugins/New_GPG/src/options.cpp
index c3d9a93f69..bd74f71666 100755
--- a/plugins/New_GPG/src/options.cpp
+++ b/plugins/New_GPG/src/options.cpp
@@ -356,7 +356,7 @@ static INT_PTR CALLBACK DlgProcGpgOpts(HWND hwndDlg, UINT msg, WPARAM wParam, LP
if(!szKey)
{
TCHAR msg[64];
- mir_sntprintf(msg, 64, TranslateT("Failed to lock memory with error %d"), GetLastError());
+ mir_sntprintf(msg, SIZEOF(msg), TranslateT("Failed to lock memory with error %d"), GetLastError());
MessageBox(0, msg, TranslateT("Error"), MB_OK);
GlobalFree(hMem);
}
@@ -369,7 +369,7 @@ static INT_PTR CALLBACK DlgProcGpgOpts(HWND hwndDlg, UINT msg, WPARAM wParam, LP
{
GlobalFree(hMem);
TCHAR msg[64];
- mir_sntprintf(msg, 64, TranslateT("Failed write to clipboard with error %d"), GetLastError());
+ mir_sntprintf(msg, SIZEOF(msg), TranslateT("Failed write to clipboard with error %d"), GetLastError());
MessageBox(0, msg, TranslateT("Error"), MB_OK);
}
CloseClipboard();
@@ -377,7 +377,7 @@ static INT_PTR CALLBACK DlgProcGpgOpts(HWND hwndDlg, UINT msg, WPARAM wParam, LP
else
{
TCHAR msg[64];
- mir_sntprintf(msg, 64, TranslateT("Failed to open clipboard with error %d"), GetLastError());
+ mir_sntprintf(msg, SIZEOF(msg), TranslateT("Failed to open clipboard with error %d"), GetLastError());
MessageBox(0, msg, TranslateT("Error"), MB_OK);
}
}
diff --git a/plugins/New_GPG/src/utilities.cpp b/plugins/New_GPG/src/utilities.cpp
index 9b8aec3b3e..ef3d0977e8 100755
--- a/plugins/New_GPG/src/utilities.cpp
+++ b/plugins/New_GPG/src/utilities.cpp
@@ -1541,11 +1541,11 @@ void ExportGpGKeysFunc(int type)
file.close();
TCHAR msg[512];
if(type == 2)
- mir_sntprintf(msg, 512, TranslateT("We have successfully exported %d public keys and all private keys."), exported_keys);
+ mir_sntprintf(msg, SIZEOF(msg), TranslateT("We have successfully exported %d public keys and all private keys."), exported_keys);
else if(type == 1)
- mir_sntprintf(msg, 512, TranslateT("We have successfully exported all private keys."));
+ mir_sntprintf(msg, SIZEOF(msg), TranslateT("We have successfully exported all private keys."));
else if(!type)
- mir_sntprintf(msg, 512, TranslateT("We have successfully exported %d public keys."), exported_keys);
+ mir_sntprintf(msg, SIZEOF(msg), TranslateT("We have successfully exported %d public keys."), exported_keys);
MessageBox(NULL, msg, TranslateT("Keys export result"), MB_OK);
}
@@ -1890,9 +1890,9 @@ INT_PTR ImportGpGKeys(WPARAM w, LPARAM l)
file.close();
TCHAR msg[512];
if(processed_private_keys)
- mir_sntprintf(msg, 512, TranslateT("We have successfully processed %d public keys and some private keys."), processed_keys);
+ mir_sntprintf(msg, SIZEOF(msg), TranslateT("We have successfully processed %d public keys and some private keys."), processed_keys);
else
- mir_sntprintf(msg, 512, TranslateT("We have successfully processed %d public keys."), processed_keys);
+ mir_sntprintf(msg, SIZEOF(msg), TranslateT("We have successfully processed %d public keys."), processed_keys);
MessageBox(NULL, msg, TranslateT("Keys import result"), MB_OK);
return 0;
}