From 3afdbdbd8e5b7a41313ee60c25abd27c0f656efd Mon Sep 17 00:00:00 2001 From: Dj Merrill Date: Sun, 5 May 2024 13:08:47 -0400 Subject: [PATCH] Check for rigctld at exit and stop it if needed --- tools/Linux/run-freedata-linux.sh | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/tools/Linux/run-freedata-linux.sh b/tools/Linux/run-freedata-linux.sh index d4237704..2fe3f0ab 100755 --- a/tools/Linux/run-freedata-linux.sh +++ b/tools/Linux/run-freedata-linux.sh @@ -15,6 +15,8 @@ # We expect the config.ini file to be at $HOME/.config/FreeDATA/config.ini # If it isn't found, we copy config.ini.example there # +# 1.5: 05 May 2024 +# Check for rigctld at exit and stop it if needed # 1.4: 05 May 2024 # Added comments on how to view log outputs in realtime # 1.3: 02 May 2024 @@ -120,5 +122,16 @@ echo "Stopping the server component" echo "*************************************************************************" kill $serverpid +# If rigctld is still running, stop it +checkrigctld=`ps auxw | grep -i rigctld | grep -v grep` +if [ ! -z "$checkrigctld" ]; +then + echo "*************************************************************************" + echo "Stopping rigctld" + echo "*************************************************************************" + rigpid=`echo $checkrigctld | cut -f2 -d" "` + kill $rigpid +fi + # Return to the directory we started in cd ..