Skip to content

Commit

Permalink
[ipcamera] Fix orphan ffmpeg process after stopping stream URL (openh…
Browse files Browse the repository at this point in the history
…ab#14909)

* Setting ffmpeg reference 'ffmpegMjpeg' to null after stopping convertion to fix automatic restart of ffmpeg process.

---------

Signed-off-by: Thomas Burri <[email protected]>
Signed-off-by: Matt Myers <[email protected]>
  • Loading branch information
tb4jc authored and matchews committed Aug 9, 2023
1 parent 7f909e5 commit ea3aa0f
Showing 1 changed file with 3 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -212,6 +212,9 @@ public void run() {
Ffmpeg localMjpeg = handler.ffmpegMjpeg;
if (localMjpeg != null) {
localMjpeg.stopConverting();
// Set reference to ffmpegMjpeg to null to prevent automatic reconnection
// in handler's pollCameraRunnable() check for frozen camera
handler.ffmpegMjpeg = null;
}
} else {
handler.closeChannel(handler.getTinyUrl(handler.mjpegUri));
Expand Down

0 comments on commit ea3aa0f

Please sign in to comment.