summaryrefslogtreecommitdiff
path: root/plugins/Popup/src/opttree.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/Popup/src/opttree.cpp')
-rw-r--r--plugins/Popup/src/opttree.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/plugins/Popup/src/opttree.cpp b/plugins/Popup/src/opttree.cpp
index 52ead4fe51..1c670e06b0 100644
--- a/plugins/Popup/src/opttree.cpp
+++ b/plugins/Popup/src/opttree.cpp
@@ -36,7 +36,6 @@ static void OptTree_TranslateItem(HWND hwndTree, HTREEITEM hItem)
tvi.cchTextMax = SIZEOF(buf);
SendMessage(hwndTree, TVM_GETITEMW, 0, (LPARAM)&tvi);
tvi.pszText = TranslateTS(tvi.pszText);
- tvi.cchTextMax = lstrlen(tvi.pszText);
SendMessage(hwndTree, TVM_SETITEMW, 0, (LPARAM)&tvi);
}
@@ -81,7 +80,7 @@ HTREEITEM OptTree_FindNamedTreeItemAt(HWND hwndTree, HTREEITEM hItem, const TCHA
tvi.mask = TVIF_TEXT;
tvi.pszText = str;
- tvi.cchTextMax = MAX_PATH;
+ tvi.cchTextMax = SIZEOF(str);
while (tvi.hItem) {
TreeView_GetItem(hwndTree, &tvi);