diff --git a/src/stream.ts b/src/stream.ts index 7e17922..f7a78f0 100644 --- a/src/stream.ts +++ b/src/stream.ts @@ -269,6 +269,11 @@ export class YamuxStream extends AbstractStream { * potentially sends a window update enabling further writes to take place. */ sendWindowUpdate (): void { + // only send window updates if the read status is ready + if (this.readStatus !== 'ready') { + return + } + // determine the flags if any const flags = this.getSendFlags()