Skip to content
This repository has been archived by the owner on Jul 18, 2024. It is now read-only.

Commit

Permalink
Reduce max. buffer size from 2G to 600MB (#7466)
Browse files Browse the repository at this point in the history
Reverts the max. buffered size to 600 MB. We have seen [issues with
Chrome on Linux](https://issues.chromium.org/u/1/issues/324519298) where
allocation of Uint8Arrays can cause the app to crash. Reducing the max.
buffered size mitigates these issues.
  • Loading branch information
achim-k authored Feb 10, 2024
1 parent 60d7469 commit 22929f4
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -200,10 +200,10 @@ export class IterablePlayer implements Player {
this.#bufferImpl = new BufferedIterableSource(source);
this.#bufferedSource = new DeserializedSourceWrapper(this.#bufferImpl);
} else {
const GIGABYTE_IN_BYTES = 1024 * 1024 * 1024;
const MEGABYTE_IN_BYTES = 1024 * 1024;
const bufferInterface = new BufferedIterableSource(source, {
readAheadDuration: { sec: 120, nsec: 0 },
maxCacheSizeBytes: 2 * GIGABYTE_IN_BYTES,
maxCacheSizeBytes: 600 * MEGABYTE_IN_BYTES,
});
this.#bufferImpl = bufferInterface;
this.#bufferedSource = new DeserializingIterableSource(bufferInterface);
Expand Down

0 comments on commit 22929f4

Please sign in to comment.