mirror of
https://git.libssh.org/projects/libssh.git
synced 2026-02-07 02:39:48 +09:00
packet: Check return value when sending unimplemented
Signed-off-by: Anderson Toshiyuki Sasaki <ansasaki@redhat.com>
Reviewed-by: Andreas Schneider <asn@cryptomilk.org>
(cherry picked from commit 6a9185636f)
This commit is contained in:
committed by
Andreas Schneider
parent
3f2375e948
commit
b6e757d692
@@ -1480,7 +1480,11 @@ void ssh_packet_process(ssh_session session, uint8_t type)
|
||||
|
||||
if (rc == SSH_PACKET_NOT_USED) {
|
||||
SSH_LOG(SSH_LOG_RARE, "Couldn't do anything with packet type %d", type);
|
||||
ssh_packet_send_unimplemented(session, session->recv_seq - 1);
|
||||
rc = ssh_packet_send_unimplemented(session, session->recv_seq - 1);
|
||||
if (rc != SSH_OK) {
|
||||
SSH_LOG(SSH_LOG_RARE, "Failed to send unimplemented: %s",
|
||||
ssh_get_error(session));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user