Преглед изворни кода

Make it clear that the string comparison isn't a boolean check

Sam Lantinga пре 1 година
родитељ
комит
0b71898cb1
1 измењених фајлова са 1 додато и 1 уклоњено
  1. 1 1
      src/video/wayland/SDL_waylandvideo.c

+ 1 - 1
src/video/wayland/SDL_waylandvideo.c

@@ -131,7 +131,7 @@ static SDL_VideoDevice *Wayland_CreateDevice(void)
     /* Are we trying to connect to or are currently in a Wayland session? */
     if (!SDL_getenv("WAYLAND_DISPLAY")) {
         const char *session = SDL_getenv("XDG_SESSION_TYPE");
-        if (session && SDL_strcasecmp(session, "wayland")) {
+        if (session && SDL_strcasecmp(session, "wayland") != 0) {
             return NULL;
         }
     }