From 73c5c7c131932b81a64bcad4d29659c38694246d Mon Sep 17 00:00:00 2001 From: Rien Maertens Date: Fri, 8 Jan 2021 11:05:06 +0100 Subject: [PATCH] Terminate script when ffmplay window closes --- reStream.sh | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/reStream.sh b/reStream.sh index eec29d3..628beda 100755 --- a/reStream.sh +++ b/reStream.sh @@ -214,7 +214,7 @@ fi $receive_cmd \ | $decompress \ | $host_passthrough \ - | "$output_cmd" \ + | ("$output_cmd" \ -vcodec rawvideo \ -loglevel "$loglevel" \ -f rawvideo \ @@ -222,4 +222,6 @@ $receive_cmd \ -video_size "$width,$height" \ $window_title_option \ -i - \ - "$@" + "$@" \ + ; kill $$ + )