X-Git-Url: http://git.grml.org/?a=blobdiff_plain;f=grml-x;h=9a5fa0c3b954cbfa0dba428b03ad5cfbee48caa9;hb=refs%2Ftags%2F0.3.32;hp=97e2ae1d3e8da5ef411386b8db3120b302dacaff;hpb=421a31ad6ada01dae1fb38e9e016b3df1bba5c35;p=grml-x.git diff --git a/grml-x b/grml-x index 97e2ae1..9a5fa0c 100755 --- a/grml-x +++ b/grml-x @@ -4,9 +4,16 @@ # Authors: grml-team (grml.org), (c) Michael Prokop # Bug-Reports: see http://grml.org/bugs/ # License: This file is licensed under the GPL v2. -# Latest change: Don Jul 12 02:53:42 CEST 2007 [mika] +# Latest change: Die Sep 04 01:44:19 CEST 2007 [mika] ################################################################################ +# make sure /tmp is writeable {{{ + if ! [ -w /tmp ] ; then + echo 'Fatal: /tmp is not writeable. Can not resume therefore, sorry.' >&2 + exit 1 + fi +# }}} + # debugging {{{ # usage: DEBUG=1 grml-x ..... 2>/tmp/grml-x-debug.log if [[ $DEBUG -gt 0 ]]; then @@ -266,6 +273,7 @@ Just press Ctrl-C to cancel operation. sync() { [ -r "$MONITORINFO" ] || monitor # get monitor settings + [ -r "$MONITORINFO" ] || bailout 1 vsyncval=$(awk '/Vert. Sync Range:/{print $4}' $MONITORINFO | sed 's/-/.0 - / ; s/$/.0/' | head -1) hsyncval=$(awk '/Hor. Sync Range:/{print $4}' $MONITORINFO | sed 's/-/.0 - / ; s/$/.0/' | head -1) if [ -z $vsyncval ] ; then @@ -583,6 +591,7 @@ EndSection" writehwinfo # monitor stuff + [ -r "$HWINFO_TMP" ] || bailout 1 MONITOR=$(awk '/monitor.1:/{print $3}' $HWINFO_TMP) [[ $MONITOR != 'ddc' ]] && NODDC=yes @@ -981,7 +990,7 @@ cleanup # xinitrc {{{ if ! [ -x "$(which $WINDOWMANAGER)" ] ; then - print "$bg[black]$fg[red]${bold_color}Fatal: windowmanager $fg[blue]$WINDOWMANAGER$fg[red] not executable, startx won' work.${reset_color}">&2 + print "$bg[black]$fg[red]${bold_color}Fatal: windowmanager $fg[blue]$WINDOWMANAGER$fg[red] not executable, startx will not work.${reset_color}">&2 bailout fi if [ -w "$XINITRC" ] ; then