Fix X11 errors on switch.