wayland/x11's env checking shouldn't be else if just if
All checks were successful
pyrite-dev/milsko/pipeline/head This commit looks good

This commit is contained in:
IoI_xD 2026-04-08 12:00:48 -07:00
commit c0bfb51601
2 changed files with 8 additions and 4 deletions

View file

@ -2581,9 +2581,11 @@ static int MwLLWaylandCallInitImpl(void) {
if(getenv("MILSKO_BACKEND")) {
loadWayland |=
(strcmp(getenv("MILSKO_BACKEND"), "wayland") == 0);
} else if(getenv("XDG_SESSION_TYPE")) {
}
if(getenv("XDG_SESSION_TYPE")) {
loadWayland |= (strcmp(getenv("XDG_SESSION_TYPE"), "wayland") == 0);
} else if(getenv("WAYLAND_DISPLAY")) {
}
if(getenv("WAYLAND_DISPLAY")) {
loadWayland |= (getenv("WAYLAND_DISPLAY") != NULL);
}

View file

@ -1280,9 +1280,11 @@ static int MwLLX11CallInitImpl(void) {
if(getenv("MILSKO_BACKEND")) {
loadX11 |=
(strcmp(getenv("MILSKO_BACKEND"), "x11") == 0);
} else if(getenv("XDG_SESSION_TYPE")) {
}
if(getenv("XDG_SESSION_TYPE")) {
loadX11 |= (strcmp(getenv("XDG_SESSION_TYPE"), "x11") == 0);
} else if(getenv("DISPLAY")) {
}
if(getenv("DISPLAY")) {
loadX11 |= (getenv("DISPLAY") != NULL);
}