mirror of
https://github.com/demostf/demo.js
synced 2026-06-03 16:44:12 +02:00
larger encode streams
This commit is contained in:
parent
e0a641878b
commit
77252f1a99
1 changed files with 1 additions and 1 deletions
|
|
@ -17,7 +17,7 @@ export function getStream(data: string | number[]) {
|
|||
export type Encoder = (data: any, stream: BitStream) => void;
|
||||
|
||||
export function assertEncoder(parser: Parser, encoder: Encoder, data: any, length: number = 0, message: string = '') {
|
||||
const stream = new BitStream(new ArrayBuffer(Math.max(64, (length + 1) * 8)));
|
||||
const stream = new BitStream(new ArrayBuffer(Math.max(64000, (length + 1) * 8)));
|
||||
|
||||
encoder(data as Packet, stream);
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue