File tree Expand file tree Collapse file tree 4 files changed +1
-5
lines changed Expand file tree Collapse file tree 4 files changed +1
-5
lines changed Original file line number Diff line number Diff line change @@ -562,7 +562,6 @@ impl Session {
562562 if wants_reply == 1 {
563563 trace ! ( "Received keep alive message: {req:?}" , ) ;
564564 self . common . wants_reply = false ;
565- self . common . ever_received_keepalive = true ;
566565 push_packet ! ( enc. write, enc. write. push( msg:: REQUEST_SUCCESS ) ) ;
567566 } else {
568567 warn ! ( "Received keepalive without reply request!" ) ;
Original file line number Diff line number Diff line change @@ -889,7 +889,6 @@ where
889889 alive_timeouts : 0 ,
890890 received_data : false ,
891891 remote_sshid : sshid. into ( ) ,
892- ever_received_keepalive : false ,
893892 } ,
894893 session_receiver,
895894 session_sender,
@@ -1075,7 +1074,7 @@ impl Session {
10751074 reading. set( start_reading( stream_read, buffer, opening_cipher) ) ;
10761075 }
10771076 ( ) = & mut keepalive_timer => {
1078- if self . common. config. keepalive_max != 0 && self . common. alive_timeouts > self . common. config. keepalive_max && self . common . ever_received_keepalive {
1077+ if self . common. config. keepalive_max != 0 && self . common. alive_timeouts > self . common. config. keepalive_max {
10791078 debug!( "Timeout, server not responding to keepalives" ) ;
10801079 return Err ( crate :: Error :: KeepaliveTimeout . into( ) ) ;
10811080 }
Original file line number Diff line number Diff line change @@ -992,7 +992,6 @@ async fn read_ssh_id<R: AsyncRead + Unpin>(
992992 alive_timeouts : 0 ,
993993 received_data : false ,
994994 remote_sshid : sshid. into ( ) ,
995- ever_received_keepalive : false ,
996995 } ;
997996 Ok ( session)
998997}
Original file line number Diff line number Diff line change @@ -72,7 +72,6 @@ pub(crate) struct CommonSession<Config> {
7272 pub strict_kex : bool ,
7373 pub alive_timeouts : usize ,
7474 pub received_data : bool ,
75- pub ever_received_keepalive : bool ,
7675}
7776
7877impl < C > Debug for CommonSession < C > {
You can’t perform that action at this time.
0 commit comments