Skip to content

Commit d7ef872

Browse files
committed
tests: small fix for corner case condition
1 parent 52e6a63 commit d7ef872

File tree

2 files changed

+3
-4
lines changed

2 files changed

+3
-4
lines changed

src/QUICConnection.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -699,7 +699,7 @@ class QUICConnection extends EventTarget {
699699
// The error details will be available as a local error.
700700
if (e.message !== 'TlsFail') {
701701
// No other exceptions are expected
702-
utils.never();
702+
never();
703703
}
704704
}
705705

src/QUICStream.ts

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -319,9 +319,8 @@ class QUICStream
319319
this.readableController.close();
320320
}
321321
} catch (e) {
322-
if (e.message === 'Done') {
323-
never();
324-
} else {
322+
// Ignore if done, not normally meant to happen but possible in rare cases
323+
if (e.message !== 'Done') {
325324
this.logger.debug(`Stream recv reported: error ${e.message}`);
326325
if (!this._recvClosed) {
327326
// Close stream in background

0 commit comments

Comments
 (0)