mirror of
https://github.com/reactos/reactos.git
synced 2024-08-21 02:43:48 +00:00
[User32]
- Patch by Marcus Meissner : EM_REPLACESEL Handle OOM error. - Will sync to wine after a review of new WOW implementation. svn path=/trunk/; revision=44987
This commit is contained in:
parent
4c9596a9ad
commit
432bd7570f
|
@ -5004,8 +5004,8 @@ LRESULT WINAPI EditWndProc_common( HWND hwnd, UINT msg,
|
|||
{
|
||||
LPSTR textA = (LPSTR)lParam;
|
||||
INT countW = MultiByteToWideChar(CP_ACP, 0, textA, -1, NULL, 0);
|
||||
if((textW = HeapAlloc(GetProcessHeap(), 0, countW * sizeof(WCHAR))))
|
||||
MultiByteToWideChar(CP_ACP, 0, textA, -1, textW, countW);
|
||||
if(!(textW = HeapAlloc(GetProcessHeap(), 0, countW * sizeof(WCHAR)))) break;
|
||||
MultiByteToWideChar(CP_ACP, 0, textA, -1, textW, countW);
|
||||
}
|
||||
|
||||
EDIT_EM_ReplaceSel(es, (BOOL)wParam, textW, TRUE, TRUE);
|
||||
|
|
Loading…
Reference in a new issue