MessageBoxIndirectA() should check whether the MB_USERICON bit is set
to prevent an exception.
This commit is contained in:
parent
3e2af5d04f
commit
130197b8c2
|
@ -427,10 +427,16 @@ INT WINAPI MessageBoxIndirectA( LPMSGBOXPARAMSA msgbox )
|
|||
RtlCreateUnicodeStringFromAsciiz(&captionW, msgbox->lpszCaption);
|
||||
else
|
||||
captionW.Buffer = (LPWSTR)msgbox->lpszCaption;
|
||||
if (HIWORD(msgbox->lpszIcon))
|
||||
RtlCreateUnicodeStringFromAsciiz(&iconW, msgbox->lpszIcon);
|
||||
|
||||
if (msgbox->dwStyle & MB_USERICON)
|
||||
{
|
||||
if (HIWORD(msgbox->lpszIcon))
|
||||
RtlCreateUnicodeStringFromAsciiz(&iconW, msgbox->lpszIcon);
|
||||
else
|
||||
iconW.Buffer = (LPWSTR)msgbox->lpszIcon;
|
||||
}
|
||||
else
|
||||
iconW.Buffer = (LPWSTR)msgbox->lpszIcon;
|
||||
iconW.Buffer = NULL;
|
||||
|
||||
msgboxW.cbSize = sizeof(msgboxW);
|
||||
msgboxW.hwndOwner = msgbox->hwndOwner;
|
||||
|
|
Loading…
Reference in New Issue