mirror of
https://github.com/gnif/LookingGlass.git
synced 2025-04-29 10:06:28 +00:00
[client] don't override SDL_VIDEODRIVER if it is already set
This commit is contained in:
parent
607539a2af
commit
2def6346e6
@ -1014,13 +1014,16 @@ int run()
|
|||||||
if (strcmp(XDG_SESSION_TYPE, "wayland") == 0)
|
if (strcmp(XDG_SESSION_TYPE, "wayland") == 0)
|
||||||
{
|
{
|
||||||
DEBUG_INFO("Wayland detected");
|
DEBUG_INFO("Wayland detected");
|
||||||
int err = setenv("SDL_VIDEODRIVER", "wayland", 1);
|
if (getenv("SDL_VIDEO_DRIVER") == NULL)
|
||||||
if (err < 0)
|
|
||||||
{
|
{
|
||||||
DEBUG_ERROR("Unable to set the env variable SDL_VIDEODRIVER: %d", err);
|
int err = setenv("SDL_VIDEODRIVER", "wayland", 1);
|
||||||
return -1;
|
if (err < 0)
|
||||||
|
{
|
||||||
|
DEBUG_ERROR("Unable to set the env variable SDL_VIDEODRIVER: %d", err);
|
||||||
|
return -1;
|
||||||
|
}
|
||||||
|
DEBUG_INFO("SDL_VIDEODRIVER has been set to wayland");
|
||||||
}
|
}
|
||||||
DEBUG_INFO("SDL_VIDEODRIVER has been set to wayland");
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// warn about using FPS display until we can fix the font rendering to prevent lag spikes
|
// warn about using FPS display until we can fix the font rendering to prevent lag spikes
|
||||||
|
Loading…
x
Reference in New Issue
Block a user