Hi,

I noticed that with a default Fedora 32 workstation install (default GNOME3 on
Wayland session) VirtualBox crashes immediately at startup. The problem is that
QT5 now defaults to the Wayland backend and VirtualBox assumes the X11 backend
is used and makes a bunch of unchecked X11 calls which cause NULL pointer 
derefs.

The attached patch is a simple fix which fixes this by setting the QT backend
back to X11.

As usual, the patch is released under the MIT license.

Regards,

Hans
diff -up VirtualBox-6.1.4/src/VBox/Installer/linux/VBox.sh~ VirtualBox-6.1.4/src/VBox/Installer/linux/VBox.sh
--- VirtualBox-6.1.4/src/VBox/Installer/linux/VBox.sh~	2020-04-02 18:29:07.000000000 +0200
+++ VirtualBox-6.1.4/src/VBox/Installer/linux/VBox.sh	2020-04-06 10:29:16.560823901 +0200
@@ -88,6 +88,11 @@ if [ "$SHUTDOWN" = "true" ]; then
     exit 0
 fi
 
+# The VirtualBox code uses QX11Info::display() to make direct X11 calls in
+# various places, so it is not ready to run as native Wayland client yet
+# Without this "VirtualBox" crashes immediately at startup under Wayland
+export QT_QPA_PLATFORM=xcb
+
 APP=`basename $0`
 case "$APP" in
     VirtualBox|virtualbox)
_______________________________________________
vbox-dev mailing list
vbox-dev@virtualbox.org
https://www.virtualbox.org/mailman/listinfo/vbox-dev

Reply via email to