File: sdm-session

package info (click to toggle)
sdm 0.4.0a-1
  • links: PTS
  • area: main
  • in suites: sarge
  • size: 188 kB
  • ctags: 4
  • sloc: sh: 68; makefile: 66
file content (23 lines) | stat: -rwxr-xr-x 648 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
#!/bin/ash
#/usr/bin/sdm-session

# Copyright 2003 under the terms of the GNU General Public
# License, version 2 or any later version. vagrant@freegeek.org

# no longer "exec"s Xsession, so that we can kill sshd if 
# needed later...
if [ -x /etc/sdm/Xsession ]; then
	/etc/sdm/Xsession $@
elif [ -x /etc/X11/Xsession ]; then
	/etc/X11/Xsession $1
elif [ -x $(which $1) ]; then
  $1
else
  echo "not able to find login session"
  xmessage -timeout 15 -center "not able to find login session"
fi

# kill the parent-process id, sshd.
# it's kind of crude, but prevents sdm from hanging if the
# user was running backgrounded processes...
kill $PPID