Loop a held send on the gate's own answer, not on the socket too

This commit is contained in:
2026-09-01 10:15:07 +02:00
parent 35dd1e7678
commit 58817eebbf
2 changed files with 9 additions and 2 deletions
+2 -1
View File
@@ -189,7 +189,8 @@ export class Session extends EventEmitter<SessionEvents> {
const attempt = await this.attempt(input, options).finally(() => { this.window.release(); });
// Nothing reached the socket, so the next link carries it instead of the caller resending.
if (!attempt.retryOnNextLink || !this.linkDown() || !this.retrying()) return attempt.result;
// The gate's own answer, or a loop round one that admits everything spins on a dead socket.
if (!attempt.retryOnNextLink || this.gate.isUp() || !this.retrying()) return attempt.result;
}
}