mirror of
https://github.com/ApfelTeeSaft/reactos.git
synced 2026-09-01 04:13:35 +00:00
[WIN32K]
- IntCreateWindow: Fill out MaximumLength field of the window name. Fixes potential buffer overflow in at least NtUserDefSetText. svn path=/trunk/; revision=50135
This commit is contained in:
@@ -1759,6 +1759,7 @@ PWND FASTCALL IntCreateWindow(CREATESTRUCTW* Cs,
|
||||
RtlCopyMemory(pWnd->strName.Buffer, WindowName->Buffer, WindowName->Length);
|
||||
pWnd->strName.Buffer[WindowName->Length / sizeof(WCHAR)] = L'\0';
|
||||
pWnd->strName.Length = WindowName->Length;
|
||||
pWnd->strName.MaximumLength = WindowName->Length + sizeof(UNICODE_NULL);
|
||||
}
|
||||
|
||||
/* Correct the window style. */
|
||||
|
||||
Reference in New Issue
Block a user