mirror of
https://github.com/Relintai/sdl2_frt.git
synced 2025-04-16 21:46:03 +02:00
Fix a potential crash in macOS 10.7 and earlier.
This commit is contained in:
parent
8292d73ebb
commit
e0ea4da4ae
@ -392,7 +392,10 @@ Cocoa_GetDisplayModes(_THIS, SDL_VideoDisplay * display)
|
|||||||
#endif
|
#endif
|
||||||
|
|
||||||
modes = CGDisplayCopyAllDisplayModes(data->display, dict);
|
modes = CGDisplayCopyAllDisplayModes(data->display, dict);
|
||||||
CFRelease(dict);
|
|
||||||
|
if (dict != NULL) {
|
||||||
|
CFRelease(dict);
|
||||||
|
}
|
||||||
|
|
||||||
if (modes) {
|
if (modes) {
|
||||||
CVDisplayLinkRef link = NULL;
|
CVDisplayLinkRef link = NULL;
|
||||||
|
Loading…
Reference in New Issue
Block a user