Fix #5605 Unblock non container Threads

reorder
This commit is contained in:
gregw 2021-02-03 11:27:25 +01:00
parent a100d80d26
commit 25cbe652a0
1 changed files with 3 additions and 2 deletions

View File

@ -450,11 +450,12 @@ public class HttpOutput extends ServletOutputStream implements Runnable
break; break;
case BLOCKED: case BLOCKED:
// An operation is in progress, so we soft close now
_softClose = true;
// then cancel the operation
CancellationException cancelled = new CancellationException(); CancellationException cancelled = new CancellationException();
if (_writeBlocker.fail(cancelled)) if (_writeBlocker.fail(cancelled))
_channel.abort(cancelled); _channel.abort(cancelled);
// An operation is in progress, so we soft close now
_softClose = true;
// then trigger a close from onWriteComplete // then trigger a close from onWriteComplete
_state = State.CLOSE; _state = State.CLOSE;
break; break;