aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNyanmisaka <nst799610810@gmail.com>2025-04-08 20:58:55 +0000
committerGitHub <noreply@github.com>2025-04-08 14:58:55 -0600
commit98697e75ca112a2047f3735f0904c401e20e4e40 (patch)
tree133f790ae45bba3fd4b2ed97ec147e3c8d58cb23
parent1e10cd003d4e5b99c45c56fde30b0bcc90233888 (diff)
Fix seeking beyond EOF again (#13871)
-rw-r--r--MediaBrowser.Controller/MediaEncoding/EncodingHelper.cs4
1 files changed, 2 insertions, 2 deletions
diff --git a/MediaBrowser.Controller/MediaEncoding/EncodingHelper.cs b/MediaBrowser.Controller/MediaEncoding/EncodingHelper.cs
index aed7820a6..2ba6ceea6 100644
--- a/MediaBrowser.Controller/MediaEncoding/EncodingHelper.cs
+++ b/MediaBrowser.Controller/MediaEncoding/EncodingHelper.cs
@@ -2872,10 +2872,10 @@ namespace MediaBrowser.Controller.MediaEncoding
var seekTick = isHlsRemuxing ? time + 5000000L : time;
// Seeking beyond EOF makes no sense in transcoding. Clamp the seekTick value to
- // [0, RuntimeTicks - 0.5s], so that the muxer gets packets and avoid error codes.
+ // [0, RuntimeTicks - 5.0s], so that the muxer gets packets and avoid error codes.
if (maxTime > 0)
{
- seekTick = Math.Clamp(seekTick, 0, Math.Max(maxTime - 5000000L, 0));
+ seekTick = Math.Clamp(seekTick, 0, Math.Max(maxTime - 50000000L, 0));
}
seekParam += string.Format(CultureInfo.InvariantCulture, "-ss {0}", _mediaEncoder.GetTimeParameter(seekTick));