File: sdm-session

package info (click to toggle)
sdm 0.4.1-4
  • links: PTS, VCS
  • area: main
  • in suites: squeeze
  • size: 204 kB
  • ctags: 13
  • sloc: sh: 86; makefile: 17
file content (24 lines) | stat: -rwxr-xr-x 698 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
24
#!/bin/dash
#/usr/bin/sdm-session

# Copyright 2003-2007 Vagrant Cascadian <vagrant@freegeek.org>.
# Licensed under the terms of the GNU General Public License,
# version 2 or any later version.

# 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