We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 72552d2 commit 78d8e42Copy full SHA for 78d8e42
Video/video.sh
@@ -142,12 +142,12 @@ function exit_on_max_session_reach() {
142
143
function stop_ffmpeg() {
144
while true; do
145
- FFMPEG_PID=$(pgrep -f ffmpeg | tr '\n' ' ')
+ FFMPEG_PID=$(pgrep -f "ffmpeg -hide_banner" | tr '\n' ' ')
146
if [ -n "$FFMPEG_PID" ]; then
147
kill -SIGTERM $FFMPEG_PID
148
wait $FFMPEG_PID
149
fi
150
- if ! pgrep -f ffmpeg >/dev/null; then
+ if ! pgrep -f "ffmpeg -hide_banner" >/dev/null; then
151
break
152
153
sleep ${poll_interval}
@@ -169,7 +169,7 @@ function stop_recording() {
169
}
170
171
function check_if_ffmpeg_running() {
172
- if pgrep -f ffmpeg >/dev/null; then
+ if pgrep -f "ffmpeg -hide_banner" >/dev/null; then
173
return 0
174
175
return 1
0 commit comments