diff options
author | Darrell Anderson <[email protected]> | 2014-02-24 12:56:37 -0600 |
---|---|---|
committer | Darrell Anderson <[email protected]> | 2014-02-24 12:56:37 -0600 |
commit | 77aed4a4eba63e760c40cc5b3d1ad556cad5c40f (patch) | |
tree | ee26a0d18c936352e69a3a93ea244c13d286949c /starttde | |
parent | 3545330be06081c9fdc2546bf465d9a2c5d24f75 (diff) | |
download | tdebase-77aed4a4eba63e760c40cc5b3d1ad556cad5c40f.tar.gz tdebase-77aed4a4eba63e760c40cc5b3d1ad556cad5c40f.zip |
Add nominal preventive maintenance in starttde.
Diffstat (limited to 'starttde')
-rw-r--r-- | starttde | 16 |
1 files changed, 16 insertions, 0 deletions
@@ -405,6 +405,17 @@ fi dl=$DESKTOP_LOCKED unset DESKTOP_LOCKED # Don't want it in the environment +# Clean house in case a previous session was terminated abruptly. +# When left hanging these two processes interfere with starting Trinity. +DESKTOP_LOCK="`ps aux | grep $USER | grep kdesktop_lock | grep -v grep | awk '{print $2}'`" +if [ "$DESKTOP_LOCK" != "" ]; then + kill -9 $DESKTOP_LOCK &>/dev/null +fi +DCOP="`ps aux | grep $USER | grep dcopserver | grep -v grep | awk '{print $2}'`" +if [ "$DCOP" != "" ]; then + kill -9 $DCOP &>/dev/null +fi + # Launch splash that doesn't need any TDE libraries here, before # TDE libraries are loaded into memory (which may take some time # with cold caches). Makes the splash appear sooner. @@ -740,6 +751,11 @@ echo "[starttde] Shutting down Trinity..." 1>&2 $TDEDIR/bin/tdeinit_shutdown $TDEDIR/bin/dcopserver_shutdown --wait $TDEDIR/bin/artsshell -q terminate +# Sometimes gamin prevents halting or rebooting a system. Just terminate the process now. +GAM_SERVER="`ps aux | grep $USER | grep gam_server | grep -v grep | awk '{print $2}'`" +if [ "$GAM_SERVER" != "" ]; then + kill -9 $GAM_SERVER 2>/dev/null +fi # KDE4 support. if [ -f /usr/bin/kdeinit4_shutdown ]; then /usr/bin/kde4 kdeinit4_shutdown 2>/dev/null |