summaryrefslogtreecommitdiff
path: root/plugins/TabSRMM/src/msgdialog.cpp
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2024-04-22 19:33:29 +0300
committerGeorge Hazan <george.hazan@gmail.com>2024-04-22 19:33:29 +0300
commitf4a296b2a5d331ae83eec693ad17e0be92a479eb (patch)
tree4b6f7207cb5a12e37f3b83705b22f72a73487bf3 /plugins/TabSRMM/src/msgdialog.cpp
parent8a055f1fb6d9a0ccdeda38f4839840d4d3e549c0 (diff)
fixes #4371 (tabSRMM: опция "ограничить журнал X сообщениями" неправильно считает количество сообщений)
Diffstat (limited to 'plugins/TabSRMM/src/msgdialog.cpp')
-rw-r--r--plugins/TabSRMM/src/msgdialog.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/plugins/TabSRMM/src/msgdialog.cpp b/plugins/TabSRMM/src/msgdialog.cpp
index 6cee6c70b6..acc0cfc38c 100644
--- a/plugins/TabSRMM/src/msgdialog.cpp
+++ b/plugins/TabSRMM/src/msgdialog.cpp
@@ -460,7 +460,7 @@ bool CMsgDialog::OnInitDialog()
m_maxHistory = M.GetDword(m_hContact, "maxhist", M.GetDword("maxhist", 0));
m_curHistory = 0;
if (m_maxHistory)
- m_hHistoryEvents = (MEVENT*)mir_alloc(m_maxHistory * sizeof(MEVENT));
+ m_hHistoryEvents = (MEVENT*)mir_alloc((m_maxHistory+1) * sizeof(MEVENT));
else
m_hHistoryEvents = nullptr;