#!/bin/sh
exit_msg() {
xmessage -buttons Exit "$@"
exit 1
}
[ ! -e ~/.xsession ] && exit_msg "File ~/.xsession doesn't exist."
[ ! -x ~/.xsession ] && exit_msg "File ~/.xsession not executable."
exec ~/.xsession