From 8dc2c345e1c6304505fd2d120daa55f42467520c Mon Sep 17 00:00:00 2001 From: Bob Mottram Date: Thu, 3 Sep 2015 18:21:37 +0100 Subject: [PATCH] Kill web processes on mesh stop --- src/freedombone-client | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/freedombone-client b/src/freedombone-client index ad8797eb..e0ed0b9b 100755 --- a/src/freedombone-client +++ b/src/freedombone-client @@ -404,6 +404,13 @@ function mesh_batman { echo ' if [ -f /usr/local/share/toxic/DHTnodes.internet ]; then' >> $batman_script echo ' mv /usr/local/share/toxic/DHTnodes.internet /usr/local/share/toxic/DHTnodes' >> $batman_script echo ' fi' >> $batman_script + echo '' >> $batman_script + echo ' # kill processes' >> $batman_script + echo ' zeronet_proc=$(ps aux | grep zeronet | awk -F " " "{print $2}" | head -n1)' >> $batman_script + echo ' kill -9 $zeronet_proc > /dev/null' >> $batman_script + echo ' tracker_proc=$(ps aux | grep bttrack | awk -F " " "{print $2}" | head -n1)' >> $batman_script + echo ' kill -9 $tracker_proc > /dev/null' >> $batman_script + echo '' >> $batman_script echo ' ' >> $batman_script echo ' rm -f /tmp/meshtype' >> $batman_script echo '}' >> $batman_script