mirror of
https://gitlab.freedesktop.org/wlroots/wlroots.git
synced 2025-10-31 22:25:21 -04:00
The following situation can be dangerous: - Output DP-1 is plugged in, compositor enables it. - User VT switches away. - User unplugs DP-1. - User VT switches back. - scan_drm_connectors() figures out the output is now disconnected, uninitializes the struct wlr_output. - The loop restoring previous output state in handle_session_active() accesses the struct wlr_output to figure out what to restore. By chance, we zero out the struct wlr_output after uninitializing it, so enabled and current_mode will always be zero. But let's make sure we handle this case explicitly, to remind future readers that it exists and make the code less fragile. |
||
|---|---|---|
| .. | ||
| atomic.c | ||
| backend.c | ||
| cvt.c | ||
| drm.c | ||
| gen_pnpids.sh | ||
| legacy.c | ||
| meson.build | ||
| monitor.c | ||
| properties.c | ||
| renderer.c | ||
| util.c | ||