Merge pull request #2641 from marienz/inhibit-crash

Fix crash when an idle-inhibiting client exits
This commit is contained in:
Drew DeVault 2018-09-16 10:19:14 -04:00 committed by GitHub
commit 5192f74be1
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -44,7 +44,7 @@ void idle_inhibit_v1_check_active(
struct sway_idle_inhibitor_v1 *inhibitor; struct sway_idle_inhibitor_v1 *inhibitor;
bool inhibited = false; bool inhibited = false;
wl_list_for_each(inhibitor, &manager->inhibitors, link) { wl_list_for_each(inhibitor, &manager->inhibitors, link) {
if (!inhibitor->view) { if (!inhibitor->view || !inhibitor->view->container) {
/* Cannot guess if view is visible so assume it is */ /* Cannot guess if view is visible so assume it is */
inhibited = true; inhibited = true;
break; break;