diff options
author | Mike Gabriel <mike.gabriel@das-netzwerkteam.de> | 2017-03-21 19:36:16 +0100 |
---|---|---|
committer | Mike Gabriel <mike.gabriel@das-netzwerkteam.de> | 2017-03-21 19:36:16 +0100 |
commit | dccbae23c1eab0150ad5c4aed95a06a219215437 (patch) | |
tree | 67780e9f94e8a348005101f36d1dc8dc7c3e6281 /bin | |
parent | ed600a86661c2a6f018a0dc1e00344c5a7302eaf (diff) | |
download | surf-display-dccbae23c1eab0150ad5c4aed95a06a219215437.tar.gz surf-display-dccbae23c1eab0150ad5c4aed95a06a219215437.tar.bz2 surf-display-dccbae23c1eab0150ad5c4aed95a06a219215437.zip |
midori-display: Handle situations where the Xserver has died and xprintidle does not produce output.
Diffstat (limited to 'bin')
-rwxr-xr-x | bin/midori-display | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/bin/midori-display b/bin/midori-display index 7204f6c..f54056b 100755 --- a/bin/midori-display +++ b/bin/midori-display @@ -234,7 +234,7 @@ function midori_loop { ( while [ -e "$session_lock" ]; do sleep 1 - if [ `xprintidle` -gt $(($INACTIVITY_INTERVAL*1000)) ]; then + if [ `xprintidle 2>/dev/null || echo 0` -gt $(($INACTIVITY_INTERVAL*1000)) ]; then echo -n "RESTART" > $midori_lock $OUTPUT "INFO: Triggering browser restart, too much idling around..." # reset X11 idle counter by some harmless key event |