From ebd72cf0eb798a160dce6b805c6ecd50830450c6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?F=C3=A9lix=20MARQUET?= Date: Thu, 11 Apr 2024 19:11:11 +0200 Subject: [PATCH] Kill the camera --- startup.sh | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/startup.sh b/startup.sh index c819143..3385666 100644 --- a/startup.sh +++ b/startup.sh @@ -72,7 +72,8 @@ monitor_all() { for other_pid in "${pids[@]}"; do if [ "$other_pid" != "$pid" ]; then if ps -p $other_pid -o comm= | grep -q "camera"; then - screen -S camera -X quit + screen_pid=$(ps -ef | grep "SCREEN -dmS camera" | grep -v grep | awk '{print $2}') + kill -SIGKILL $screen_pid 2>/dev/null continue fi kill -SIGKILL $other_pid 2>/dev/null