#1086518 startx: $userserverrc is not set if $XSERVERRC exists

Package:
xinit
Source:
xinit
Description:
X server initialisation tool
Submitter:
0xfa
Date:
2024-10-31 17:45:02 UTC
Severity:
normal
#1086518#5
Date:
2024-10-31 16:53:24 UTC
From:
To:
Dear mantainer,

this line of the startx script wrongly sets the $userclientrc variable
instead of the $userserverrc variable if the file specified in the
$XSERVERRC variable exists:

	[ -f "${XSERVERRC}" ] && userclientrc="${XSERVERRC}"

Patch:
--- /usr/bin/startx	2024-10-31 13:41:58.794473583 -0300
+++ /usr/bin/startx.new	2024-10-31 13:42:06.206454416 -0300
@@ -18,7 +18,7 @@
 sysclientrc=/etc/X11/xinit/xinitrc

 userserverrc=$HOME/.xserverrc
-[ -f "${XSERVERRC}" ] && userclientrc="${XSERVERRC}"
+[ -f "${XSERVERRC}" ] && userserverrc="${XSERVERRC}"
 sysserverrc=/etc/X11/xinit/xserverrc
 defaultclient=/usr/bin/xterm
 defaultserver=/usr/bin/X


Thanks,