浏览代码

Fix trickplay extraction ffmpeg error-handling (#14493)

jkhsjdhjs 1 周之前
父节点
当前提交
663087b155
共有 1 个文件被更改,包括 1 次插入4 次删除
  1. 1 4
      MediaBrowser.MediaEncoding/Encoder/MediaEncoder.cs

+ 1 - 4
MediaBrowser.MediaEncoding/Encoder/MediaEncoder.cs

@@ -1071,11 +1071,8 @@ namespace MediaBrowser.MediaEncoding.Encoder
                     }
                     }
                 }
                 }
 
 
-                var exitCode = ranToCompletion ? processWrapper.ExitCode ?? 0 : -1;
-
-                if (exitCode == -1)
+                if (!ranToCompletion || processWrapper.ExitCode != 0)
                 {
                 {
-                    _logger.LogError("ffmpeg image extraction failed for {ProcessDescription}", processDescription);
                     // Cleanup temp folder here, because the targetDirectory is not returned and the cleanup for failed ffmpeg process is not possible for caller.
                     // Cleanup temp folder here, because the targetDirectory is not returned and the cleanup for failed ffmpeg process is not possible for caller.
                     // Ideally the ffmpeg should not write any files if it fails, but it seems like it is not guaranteed.
                     // Ideally the ffmpeg should not write any files if it fails, but it seems like it is not guaranteed.
                     try
                     try