summaryrefslogtreecommitdiff
path: root/plugins/BasicHistory/src/EventList.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/BasicHistory/src/EventList.cpp')
-rw-r--r--plugins/BasicHistory/src/EventList.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/plugins/BasicHistory/src/EventList.cpp b/plugins/BasicHistory/src/EventList.cpp
index 6a822b8312..d114f3eae6 100644
--- a/plugins/BasicHistory/src/EventList.cpp
+++ b/plugins/BasicHistory/src/EventList.cpp
@@ -492,10 +492,10 @@ std::wstring EventList::GetContactId()
static void GetMessageDescription( DBEVENTINFO *dbei, TCHAR* buf, int cbBuf )
{
- TCHAR* msg = DbGetEventTextT( dbei, CP_ACP );
- _tcsncpy_s(buf, cbBuf, msg ? msg : TranslateT("Invalid Message"), cbBuf - 1 );
- buf[ cbBuf-1 ] = 0;
- mir_free( msg );
+ TCHAR *msg = DbGetEventTextT(dbei, CP_ACP);
+ _tcsncpy_s(buf, cbBuf, msg ? msg : TranslateT("Invalid Message"), _TRUNCATE);
+ buf[cbBuf - 1] = 0;
+ mir_free(msg);
}
void EventList::GetObjectDescription( DBEVENTINFO *dbei, TCHAR* str, int cbStr )