mirror of
https://github.com/Relintai/sdl2_frt.git
synced 2024-12-16 11:06:49 +01:00
SDL_windowsmessagebox.c (AddDialogControl): add back NULL caption check.
because AddDialogStaticIcon() sends a NULL caption -- fixes bug #5401.
This commit is contained in:
parent
90456670b5
commit
4d6eb30523
@ -314,7 +314,7 @@ static SDL_bool AddDialogControl(WIN_DialogData *dialog, WORD type, DWORD style,
|
|||||||
if (!AddDialogData(dialog, &type, sizeof(type))) {
|
if (!AddDialogData(dialog, &type, sizeof(type))) {
|
||||||
return SDL_FALSE;
|
return SDL_FALSE;
|
||||||
}
|
}
|
||||||
if (type == DLGITEMTYPEBUTTON || (type == DLGITEMTYPESTATIC && caption[0])) {
|
if (type == DLGITEMTYPEBUTTON || (type == DLGITEMTYPESTATIC && caption != NULL && caption[0])) {
|
||||||
if (!AddDialogString(dialog, caption)) {
|
if (!AddDialogString(dialog, caption)) {
|
||||||
return SDL_FALSE;
|
return SDL_FALSE;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user