diff --git a/debian/changelog b/debian/changelog index 9b29ca51..74ccc415 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,6 +1,8 @@ byobu (3.32) unreleased; urgency=low - * UNRELEASED + * usr/bin/byobu-launch, usr/bin/byobu-launcher: + - fix situation where the profile might exit 0, + and prevent a user from logging in -- Dustin Kirkland Fri, 15 Apr 2011 13:40:31 -0500 diff --git a/usr/bin/byobu-launch b/usr/bin/byobu-launch index a46db99d..d769f375 100755 --- a/usr/bin/byobu-launch +++ b/usr/bin/byobu-launch @@ -21,15 +21,16 @@ PKG="byobu" DATA="$HOME/.$PKG" case "$-" in *i*) - byobu-launcher + if byobu-launcher; then + # Wait very briefly for the no-logout flag to get written? + sleep 0.1 + if [ -e "$DATA/no-logout-on-detach" ] || [ -e "/var/run/screen/S-$USER/byobu.no-logout" ]; then + # The user does not want to logout on byobu detach + rm -f "/var/run/screen/S-$USER/byobu.no-logout" # Remove one-time no-logout flag, if it exists + true + else + exit 0 + fi + fi ;; esac -# Wait very briefly for the no-logout flag to get written? -sleep 0.1 -if [ -e "$DATA/no-logout-on-detach" ] || [ -e "/var/run/screen/S-$USER/byobu.no-logout" ]; then - # The user does not want to logout on byobu detach - rm -f "/var/run/screen/S-$USER/byobu.no-logout" # Remove one-time no-logout flag, if it exists - true -else - exit 0 -fi diff --git a/usr/bin/byobu-launcher b/usr/bin/byobu-launcher index e9dafcdf..fca35996 100755 --- a/usr/bin/byobu-launcher +++ b/usr/bin/byobu-launcher @@ -22,7 +22,9 @@ DATA="$HOME/.$PKG" [ -z "$BYOBU_PREFIX" ] && export BYOBU_PREFIX="/usr" export BYOBU_PREFIX -if [ ! -e "$DATA/disable-autolaunch" ]; then +if [ -e "$DATA/disable-autolaunch" ]; then + false +else case "$TERM" in *screen*) # Handle nesting