SDL: Fixed warning C6011: Dereferencing NULL pointer 'display'.

From 4ccc53edfeb2444101dc1f3a900ea88bf45f3b89 Mon Sep 17 00:00:00 2001
From: Sam Lantinga <[EMAIL REDACTED]>
Date: Mon, 4 Dec 2023 20:35:14 -0800
Subject: [PATCH] Fixed warning C6011: Dereferencing NULL pointer 'display'.

---
 src/video/SDL_video.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/video/SDL_video.c b/src/video/SDL_video.c
index 3f416f2b738a..74cd5d50c1c7 100644
--- a/src/video/SDL_video.c
+++ b/src/video/SDL_video.c
@@ -1508,7 +1508,7 @@ static int SDL_UpdateFullscreenMode(SDL_Window *window, SDL_bool fullscreen)
                 break;
             }
         }
-        if (i == _this->num_displays) {
+        if (!display || i == _this->num_displays) {
             /* Already not fullscreen on any display */
             goto done;
         }