path: root/main/xinit/06_move_serverauthfile_into_tmp.patch
blob: 99e8a6754dfaf1d5342f47c977855aed98bf488e (plain) (tree)

Move startx auth files in /tmp so they are removed on reboot.
The trap patch didn't seem to work on reboot.
 startx.cpp |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Index: xinit/startx.cpp
--- xinit.orig/startx.cpp
+++ xinit/startx.cpp
@@ -273,7 +273,7 @@
     XCOMM create a file with auth information for the server. ':0' is a dummy.
-    xserverauthfile=$HOME/.serverauth.$$
+    xserverauthfile=`mktemp -p /tmp serverauth.XXXXXXXXXX`
     trap "rm -f '$xserverauthfile'" HUP INT QUIT ILL TRAP KILL BUS TERM
     xauth -q -f "$xserverauthfile" << EOF
 add :$dummy . $mcookie