Ported from https://github.com/bitcoin/bitcoin/issues/18537.
When running bitcoin qt over x11 remote session (DISPLAY=1.2.3.4:0) in a clean machine, wallet stops with error.
Expected behavior
Initial intro dialog (were to put the data files) opened.
Actual behavior
I got this:
The X11 connection broke: Maximum allowed requested length exceeded (code 4)
XIO: fatal IO error 2 (No such file or directory) on X server "192.168.200.26:51"
after 219 requests (219 known processed) with 0 events remaining.
To reproduce
Need a clean machine (~/.bitcoin sould be not exists), need a remote x11 “desktop”.
export DISPLAY=1.2.3.4:0
./bitcoin-qt
System information
ubuntu bionic/xenial tested x64/arm cpu tested remote x11 session: xvnc and pure xorg tested
The issue
Intro dialog sets the windowicon, this bitmap is 1024x1024 pixels. the qt5 convert this into argb32 format (=1 pixel 4 bytes), thats 4M data. The x11 remote connections allow only less than 4M length.
Possible fix
We dont need 1024x1024 dialog icon, just 128x128 or 256x256. So scale the icon:
intro.setWindowIcon(QIcon(QPixmap(":icons/bitcoin").scaled(QSize(128, 128), Qt::KeepAspectRatio, Qt::SmoothTransformation )));