Prevent server Connection from returning same error after calling abrupt shutdown (#352)

This commit is contained in:
Sean McArthur
2019-04-03 11:41:56 -07:00
committed by Carl Lerche
parent 8e809c3e0c
commit a3e59eb7e2
5 changed files with 71 additions and 25 deletions

View File

@@ -443,7 +443,7 @@ where
///
/// For graceful shutdowns, see [`graceful_shutdown`](Connection::graceful_shutdown).
pub fn abrupt_shutdown(&mut self, reason: Reason) {
self.connection.go_away_now(reason);
self.connection.go_away_from_user(reason);
}
/// Starts a [graceful shutdown][1] process.