diff options
author | Preston Brown <pbrown@redhat.com> | 2001-09-14 18:36:59 +0000 |
---|---|---|
committer | Preston Brown <pbrown@redhat.com> | 2001-09-14 18:36:59 +0000 |
commit | d18cf43b8e9de460064f876793483cd2e042073a (patch) | |
tree | 9d9e2d73f43c270ead8693f8cd4f08dfb27df42f /prefdm | |
parent | ef5bac4a0881eca6af93b115ec22330a2732169f (diff) | |
download | initscripts-d18cf43b8e9de460064f876793483cd2e042073a.tar initscripts-d18cf43b8e9de460064f876793483cd2e042073a.tar.gz initscripts-d18cf43b8e9de460064f876793483cd2e042073a.tar.bz2 initscripts-d18cf43b8e9de460064f876793483cd2e042073a.tar.xz initscripts-d18cf43b8e9de460064f876793483cd2e042073a.zip |
slight prefdm cleanup (i.e. no AnotherLevel support).
Diffstat (limited to 'prefdm')
-rwxr-xr-x | prefdm | 10 |
1 files changed, 6 insertions, 4 deletions
@@ -23,11 +23,9 @@ if [ -f /etc/sysconfig/desktop ]; then if [ "$DESKTOP" = GNOME ]; then preferred=gdm elif [ "$DESKTOP" = "KDE" -o "$DESKTOP" = "KDE1" -o "$DESKTOP" = "KDE2" ]; then - preferred=/usr/bin/kdm - elif [ "$DESKTOP" = AnotherLevel ] ; then - preferred=/usr/X11R6/bin/xdm - fi + preferred=kdm fi + if [ -z "$preferred" ]; then if which gdm >/dev/null 2>&1; then preferred=gdm @@ -37,9 +35,11 @@ if [ -z "$preferred" ]; then preferred=xdm fi fi + if [ -n "$preferred" ] && which $preferred >/dev/null 2>&1; then exec `which $preferred` $* >/dev/null 2>&1 fi + if which gdm >/dev/null 2>&1; then exec `which gdm` $* >/dev/null 2>&1 elif which kdm >/dev/null 2>&1; then @@ -47,4 +47,6 @@ elif which kdm >/dev/null 2>&1; then elif which xdm >/dev/null 2>&1; then exec `which xdm` $* >/dev/null 2>&1 fi + +# catch all exit error exit 1 |