Bug 1794284 [Wayland] Check critical Wayland interfaces on startup r=rmader

Differential Revision: https://phabricator.services.mozilla.com/D158955
This commit is contained in:
stransky 2022-10-11 20:10:00 +00:00
Родитель 51fc6b95d1
Коммит 26291a4850
1 изменённых файлов: 7 добавлений и 0 удалений

Просмотреть файл

@ -295,6 +295,13 @@ nsWaylandDisplay::nsWaylandDisplay(wl_display* aDisplay)
wl_display_roundtrip(mDisplay);
}
wl_registry_destroy(registry);
// Check we have critical Wayland interfaces.
// Missing ones indicates a compositor bug and we can't continue.
MOZ_DIAGNOSTIC_ASSERT(GetShm(), "We're missing shm interface!");
MOZ_DIAGNOSTIC_ASSERT(GetCompositor(), "We're missing compositor interface!");
MOZ_DIAGNOSTIC_ASSERT(GetSubcompositor(),
"We're missing subcompositor interface!");
}
nsWaylandDisplay::~nsWaylandDisplay() {