diff options
author | Kirill Volinsky <mataes2007@gmail.com> | 2013-07-24 14:52:01 +0000 |
---|---|---|
committer | Kirill Volinsky <mataes2007@gmail.com> | 2013-07-24 14:52:01 +0000 |
commit | 3e02ce14f6cce63910b266655a9c33bd3a70f17a (patch) | |
tree | 8fcf4371ea0d10693e7697f305d51988484faf69 /plugins/Exchange/src | |
parent | 107471fac771abe5774d10769e36c0903a908685 (diff) |
replace sprintf to mir_snprintf (part 4)
git-svn-id: http://svn.miranda-ng.org/main/trunk@5467 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/Exchange/src')
-rw-r--r-- | plugins/Exchange/src/emails.cpp | 15 | ||||
-rw-r--r-- | plugins/Exchange/src/utils.cpp | 8 |
2 files changed, 4 insertions, 19 deletions
diff --git a/plugins/Exchange/src/emails.cpp b/plugins/Exchange/src/emails.cpp index f13a15c1b8..03e7d719ca 100644 --- a/plugins/Exchange/src/emails.cpp +++ b/plugins/Exchange/src/emails.cpp @@ -339,21 +339,6 @@ int CExchangeServer::Check(int bNoEmailsNotify) }
ShowMessage(buffer, count);
- /*int i;
- TEmailHeader emailInfo = {0};
- char sender[1024];
- char subject[1024];
- emailInfo.cbSize = sizeof(emailInfo);
- emailInfo.szSender = sender;
- emailInfo.szSubject = subject;
- emailInfo.cSender = sizeof(sender);
- emailInfo.cSubject = sizeof(subject);
- for (i = 0; i < count; i++)
- {
- GetEmailHeader(i, &emailInfo);
- sprintf(buffer, "Unread email #%d:\nSender :%s\nSubject :%s", i + 1, sender, subject);
- ShowMessage(buffer);
- }*/
}
if (count==-1)
diff --git a/plugins/Exchange/src/utils.cpp b/plugins/Exchange/src/utils.cpp index 97aed40a68..0e5adb4831 100644 --- a/plugins/Exchange/src/utils.cpp +++ b/plugins/Exchange/src/utils.cpp @@ -46,7 +46,7 @@ int Log(char *format, ...) va_start(vararg, format);
- tBytes = _vsnprintf(str, sizeof(str), format, vararg);
+ tBytes = mir_vsnprintf(str, sizeof(str), format, vararg);
if (tBytes > 0)
{
str[tBytes] = 0;
@@ -69,7 +69,7 @@ int Info(char *title, char *format, ...) va_list vararg;
int tBytes;
va_start(vararg, format);
- tBytes = _vsnprintf(str, sizeof(str), format, vararg);
+ tBytes = mir_vsnprintf(str, sizeof(str), format, vararg);
if (tBytes > 0)
{
str[tBytes] = 0;
@@ -87,12 +87,12 @@ char *BinToHex(int size, PBYTE data) int maxSize = size * 2 + HEX_SIZE + 1;
szresult = (char *) new char[ maxSize ];
memset(szresult, 0, maxSize);
- sprintf(buffer, "%0*X", HEX_SIZE, size);
+ mir_snprintf(buffer, SIZEOF(buffer), "%0*X", HEX_SIZE, size);
strcpy(szresult, buffer);
int i;
for (i = 0; i < size; i++)
{
- sprintf(buffer, "%02X", data[i]);
+ mir_snprintf(buffer, SIZEOF(buffer), "%02X", data[i]);
strcpy(szresult + (HEX_SIZE + i * 2), buffer);
}
return szresult;
|