File tree Expand file tree Collapse file tree 2 files changed +2
-3
lines changed Expand file tree Collapse file tree 2 files changed +2
-3
lines changed Original file line number Diff line number Diff line change @@ -340,9 +340,7 @@ impl Session {
340340 if let Some ( ref mut enc) = self . common . encrypted {
341341 // The CHANNEL_CLOSE message must be sent to the server at this point or the session
342342 // will not be released.
343- if enc. channels . remove ( & channel_num) . is_some ( ) {
344- enc. byte ( channel_num, msg:: CHANNEL_CLOSE ) ;
345- }
343+ enc. close ( channel_num) ;
346344 }
347345 client. channel_close ( channel_num, self ) . await
348346 }
Original file line number Diff line number Diff line change @@ -151,6 +151,7 @@ impl Encrypted {
151151
152152 pub fn close ( & mut self , channel : ChannelId ) {
153153 self . byte ( channel, msg:: CHANNEL_CLOSE ) ;
154+ self . channels . remove ( & channel) ;
154155 }
155156
156157 pub fn sender_window_size ( & self , channel : ChannelId ) -> usize {
You can’t perform that action at this time.
0 commit comments