summaryrefslogtreecommitdiff
path: root/protocols/JabberG
diff options
context:
space:
mode:
authorRozhuk Ivan <rozhuk.im@gmail.com>2014-11-30 04:29:19 +0000
committerRozhuk Ivan <rozhuk.im@gmail.com>2014-11-30 04:29:19 +0000
commita8a11e811c3c0cc3f6d74c18c89841e9e0e87237 (patch)
tree775e65659d26870bba82b84fb584a5301606ff62 /protocols/JabberG
parent79041310665c9b0b93c368bb1f7cef5f669a419e (diff)
Multiple fixes buff size for GetText and SetText.
git-svn-id: http://svn.miranda-ng.org/main/trunk@11165 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'protocols/JabberG')
-rw-r--r--protocols/JabberG/src/jabber_iqid_muc.cpp2
-rw-r--r--protocols/JabberG/src/ui_utils.cpp1
2 files changed, 1 insertions, 2 deletions
diff --git a/protocols/JabberG/src/jabber_iqid_muc.cpp b/protocols/JabberG/src/jabber_iqid_muc.cpp
index 91187d0715..3776b525be 100644
--- a/protocols/JabberG/src/jabber_iqid_muc.cpp
+++ b/protocols/JabberG/src/jabber_iqid_muc.cpp
@@ -333,7 +333,7 @@ static INT_PTR CALLBACK JabberMucJidListDlgProc(HWND hwndDlg, UINT msg, WPARAM w
lvi.iItem = hti.iItem;
lvi.iSubItem = 0;
lvi.pszText = text;
- lvi.cchTextMax = sizeof(text);
+ lvi.cchTextMax = SIZEOF(text);
ListView_GetItem(nm->hdr.hwndFrom, &lvi);
if (lvi.lParam == (LPARAM)(-1)) {
CMString szBuffer(dat->type2str());
diff --git a/protocols/JabberG/src/ui_utils.cpp b/protocols/JabberG/src/ui_utils.cpp
index 4a5e052d84..56db0d4827 100644
--- a/protocols/JabberG/src/ui_utils.cpp
+++ b/protocols/JabberG/src/ui_utils.cpp
@@ -1586,7 +1586,6 @@ void CCtrlTreeView::TranslateItem(HTREEITEM hItem)
TCHAR buf[128];
GetItem(hItem, &tvi, buf, SIZEOF(buf));
tvi.pszText = TranslateTS(tvi.pszText);
- tvi.cchTextMax = lstrlen(tvi.pszText);
SetItem(&tvi);
}