diff --git a/src/cdm b/src/cdm index 1f1a9aa..8c7d9e0 100755 --- a/src/cdm +++ b/src/cdm @@ -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 diff --git a/src/zzz-cdm-profile.sh b/src/zzz-cdm-profile.sh index ed21f27..27cad19 100755 --- a/src/zzz-cdm-profile.sh +++ b/src/zzz-cdm-profile.sh @@ -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