Files
swift-nio-ssl/Sources/NIOOpenSSL
Cory Benfield 9b03e08e42 Flush buffered reads when we read a CLOSE_NOTIFY. (#40)
Motivation:

When we read a CLOSE_NOTIFY message, we immediately begin closing the
connection down. This *can* cause an instant close, and if that occurs
then we will have un-flushed data in the read buffer that we never
deliver.

If we receive a CLOSE_NOTIFY we will not receive more application data,
so we should deliver all that application data before we initiate the
shutdown process.

Modifications:

Unbuffer the buffered reads when we read a CLOSE_NOTIFY.

Result:

All reads will be shipped before channelInactive can fire.
2018-09-18 12:39:08 +02:00
..