Commit db8fb6f3 authored by Gerard Patel's avatar Gerard Patel Committed by Alexandre Julliard

Fixed returned length for LB_GETTEXT.

parent 3b603ec5
......@@ -762,7 +762,7 @@ static LRESULT LISTBOX_GetText( LB_DESCR *descr, INT index, LPARAM lParam, BOOL
else
{
LPSTR buffer = (LPSTR)lParam;
return WideCharToMultiByte(CP_ACP, 0, descr->items[index].str, -1, buffer, 0x7FFFFFFF, NULL, NULL);
return WideCharToMultiByte(CP_ACP, 0, descr->items[index].str, -1, buffer, 0x7FFFFFFF, NULL, NULL) - 1;
}
} else {
if (lParam)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment