diff --git a/plugins/ca.turbo.plg b/plugins/ca.turbo.plg index d69ea6b..14f569b 100644 --- a/plugins/ca.turbo.plg +++ b/plugins/ca.turbo.plg @@ -64,9 +64,9 @@ The 'post-install' script exec("mkdir -p /tmp/ca.turbo"); if ( is_file("/tmp/ca.turbo/PID") ) { echo "Stopping CA Auto Turbo Mode\n"; - $PID = file_get_contents($turboPaths['backgroundPID']); + $PID = file_get_contents("/tmp/ca.turbo/PID"); posix_kill($PID,SIGKILL); - @unlink($turboPaths['backgroundPID']); + @unlink("/tmp/ca.turbo/PID"); $descriptorspec = array( 0 => array("pipe", "r"), // stdin is a pipe that the child will read from 1 => array("pipe", "w"), // stdout is a pipe that the child will write to @@ -95,6 +95,14 @@ The 'remove' script. --> +if [[ -e /tmp/ca.turbo/PID ]] + then + logger "Stopping CA Turbo Mode" + PID=`cat /tmp/ca.turbo/PID` + logger "Terminating $PID" + kill $PID +fi + removepkg &name;-&version;-x86_64-1 rm -rf &plugdir; rm -rf /boot/config/plugins/&name;