Permalink
Browse files

Fix critical issue with exec, fixed SHLVL

  • Loading branch information...
1 parent 0679782 commit 874821041103acea505d4374af9040bc032a2317 Ghost1227 committed Jan 24, 2010
Showing with 4 additions and 1 deletion.
  1. +2 −0 src/cdm
  2. +2 −1 src/zzz-cdm-profile.sh
View
@@ -182,6 +182,8 @@ mainmenu() {
# Set wm_bin
clear
if [[ ${wm} -eq ${console} ]]; then
+ #Fix SHLVL
+ export SHLVL=$((SHLVL-1))
exec ${SHELL}
elif [[ ${wm} -eq ${halt} ]]; then
shutdownmenu
View
@@ -3,5 +3,6 @@ if [[ -z "$DISPLAY" && -z "$SSH_TTY" && $(tty) = /dev/tty* ]]; then
if [[ $EUID -eq 0 ]]; then
exec ${SHELL}
fi
- exec cdm
+ cdm
+ exit 0
fi

0 comments on commit 8748210

Please sign in to comment.