FF-1553 - aborting if more than 10 packet errors are detected

This commit is contained in:
John Andrews
2024-05-21 08:59:27 +12:00
parent f60f2b4340
commit be010acc37
3 changed files with 5 additions and 4 deletions

Binary file not shown.

Binary file not shown.

View File

@@ -284,19 +284,20 @@ public class FFMpegEncoder
}
}
private int PacketErrorCount = 0;
private int ErrorCount = 0;
private void CheckOutputLine(string line)
{
if (line.Contains("Skipping NAL unit"))
return; // just slightly ignore these
if (line.Contains("Error submitting a packet to the muxer"))
if (line.Contains("Error "))
{
if (++PacketErrorCount > 10)
if (++ErrorCount > 20)
{
// Abort
Abort("Error submitting a packet to the muxer");
Logger.ELog("Maximum number of errors triggered: " + line);
Abort(line);
}
}