1
1

Fix a possible stack overflow in agent code.

Этот коммит содержится в:
Andreas Schneider 2009-09-14 18:34:53 +02:00
родитель f28352707a
Коммит 6a3d31acb7

Просмотреть файл

@ -210,10 +210,7 @@ static int agent_talk(struct ssh_session_struct *session,
/* send length and then the request packet */ /* send length and then the request packet */
if (atomicio(session->agent->sock, payload, 4, 0) == 4) { if (atomicio(session->agent->sock, payload, 4, 0) == 4) {
buffer_get_data(request, payload, len); if (atomicio(session->agent->sock, buffer_get_rest(request), len, 0)
ssh_log(session, SSH_LOG_PACKET,
"agent_talk - sending request, payload[0] = %u", payload[0]);
if (atomicio(session->agent->sock, payload, len, 0)
!= len) { != len) {
ssh_log(session, SSH_LOG_PACKET, "atomicio sending request failed: %s", ssh_log(session, SSH_LOG_PACKET, "atomicio sending request failed: %s",
strerror(errno)); strerror(errno));