mirror of
https://github.com/WarmUpTill/SceneSwitcher.git
synced 2026-08-20 08:15:46 -05:00
Fix crash on Linux if no ewmh is available (#159)
This commit is contained in:
@@ -203,6 +203,10 @@ void GetCurrentWindowTitle(std::string &title)
|
||||
&format, &num, &bytes,
|
||||
(uint8_t **)&data);
|
||||
|
||||
if (data == nullptr) {
|
||||
return;
|
||||
}
|
||||
|
||||
int status = 0;
|
||||
XTextProperty text;
|
||||
if (xstatus == Success) {
|
||||
@@ -386,4 +390,4 @@ int secondsSinceLastInput()
|
||||
XCloseDisplay(display);
|
||||
|
||||
return idle_time;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user