memories/patches/videojs-vhs-1439.patch

14 lines
788 B
Diff
Raw Permalink Normal View History

--- ./node_modules/video.js/dist/video.es.js 2023-10-27 02:56:03.617235084 -0700
+++ ./node_modules/video.js/dist/video.es.js 2023-10-27 02:55:57.048971664 -0700
@@ -48232,7 +48232,9 @@
resetMainLoaderReplaceSegments() {
const buffered = this.tech_.buffered();
- const bufferedEnd = buffered.end(buffered.length - 1); // Set the replace segments flag to the buffered end, this forces fetchAtBuffer
+ // https://github.com/videojs/http-streaming/pull/1439
+ const bufferedEnd = buffered.length ? buffered.end(buffered.length - 1) : 0;
+ // Set the replace segments flag to the buffered end, this forces fetchAtBuffer
// on the main loader to remain, false after the resetLoader call, until we have
// replaced all content buffered ahead of the currentTime.