summaryrefslogtreecommitdiff
path: root/plugins/TabSRMM/src/sendqueue.cpp
diff options
context:
space:
mode:
authorRozhuk Ivan <rozhuk.im@gmail.com>2014-12-08 22:13:57 +0000
committerRozhuk Ivan <rozhuk.im@gmail.com>2014-12-08 22:13:57 +0000
commit13eb83bea655c3302c74a82d826d75bceb9232a2 (patch)
treeea992cbd9002e078a06e9fe65a73698eec4fbc22 /plugins/TabSRMM/src/sendqueue.cpp
parentef741fcb36d679b094e44d01714f423c34357383 (diff)
code cleanup around mir_snprintf
git-svn-id: http://svn.miranda-ng.org/main/trunk@11285 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/TabSRMM/src/sendqueue.cpp')
-rw-r--r--plugins/TabSRMM/src/sendqueue.cpp7
1 files changed, 3 insertions, 4 deletions
diff --git a/plugins/TabSRMM/src/sendqueue.cpp b/plugins/TabSRMM/src/sendqueue.cpp
index 6cc6dd33e4..fc8801cf85 100644
--- a/plugins/TabSRMM/src/sendqueue.cpp
+++ b/plugins/TabSRMM/src/sendqueue.cpp
@@ -142,11 +142,11 @@ static void DoSplitSendW(LPVOID param)
SendJob *job = sendQueue->getJobByIndex((int)param);
BOOL fFirstSend = FALSE;
WCHAR *wszSaved, savedChar;
- int iCur = 0, iSavedCur = 0, i;
+ size_t iCur = 0, iSavedCur = 0, i;
BOOL fSplitting = TRUE;
MCONTACT hContact = job->hContact;
DWORD dwFlags = job->dwFlags;
- int chunkSize = job->chunkSize / 2;
+ size_t chunkSize = job->chunkSize / 2;
char *szProto = GetContactProto(hContact);
size_t iLen = mir_strlen(job->szSendBuffer);
@@ -812,8 +812,7 @@ int SendQueue::doSendLater(int iJobIndex, TWindowData *dat, MCONTACT hContact, b
time_t now = time(0);
TCHAR tszTimestamp[30];
_tcsftime(tszTimestamp, SIZEOF(tszTimestamp), _T("%Y.%m.%d - %H:%M"), _localtime32((__time32_t *)&now));
- tszTimestamp[29] = 0;
- mir_snprintf(szKeyName, 20, "S%d", now);
+ mir_snprintf(szKeyName, SIZEOF(szKeyName), "S%d", now);
mir_sntprintf(tszHeader, SIZEOF(tszHeader), TranslateT("\n(Sent delayed. Original timestamp %s)"), tszTimestamp);
}
else mir_sntprintf(tszHeader, SIZEOF(tszHeader), _T("M%d|"), time(0));