Fixed returned length for LB_GETTEXT.
This commit is contained in:
parent
3b603ec551
commit
db8fb6f387
|
@ -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)
|
||||
|
|
Loading…
Reference in New Issue