From 865199e5ecfef5369080efab14ad0e0561ea502f Mon Sep 17 00:00:00 2001 From: Liam Date: Sat, 2 Mar 2024 13:55:48 +0000 Subject: [PATCH] john --- unifi/cams/base.py | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/unifi/cams/base.py b/unifi/cams/base.py index d3d2c4e..7d2265f 100644 --- a/unifi/cams/base.py +++ b/unifi/cams/base.py @@ -938,14 +938,16 @@ class UnifiCamBase(metaclass=ABCMeta): # f" {destination[0]} {destination[1]}" # ) cmd = ( - "ffmpeg -nostdin -loglevel debug -y" - f" {self.get_base_ffmpeg_args(stream_index)}" - f' -i "{source}"' - f" {self.get_extra_ffmpeg_args(stream_index)} -metadata streamName={stream_name} -f flv -" - f" | nc {destination[0]} {destination[1]}" + "ffmpeg -nostdin -loglevel debug -y " + f"{self.get_base_ffmpeg_args(stream_index)} " + f'-i "{source}" ' + f"{self.get_extra_ffmpeg_args(stream_index)} " + f"-metadata streamName={stream_name} -f flv - " + f"| nc {destination[0]} {destination[1]}" ) + if is_dead: self.logger.warn(f"Previous ffmpeg process for {stream_index} died.")