Do the appropriate accounting when ip_output() fails.

This commit is contained in:
Michael Tuexen 2018-05-21 14:52:18 +00:00
parent 95844fce7d
commit d3132db2b5
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=333980

View File

@ -11030,9 +11030,8 @@ sctp_send_resp_msg(struct sockaddr *src, struct sockaddr *dst,
struct sctp_chunkhdr *ch;
#if defined(INET) || defined(INET6)
struct udphdr *udp;
int ret __unused;
#endif
int len, cause_len, padding_len;
int ret, len, cause_len, padding_len;
#ifdef INET
struct sockaddr_in *src_sin, *dst_sin;
struct ip *ip;
@ -11259,9 +11258,13 @@ sctp_send_resp_msg(struct sockaddr *src, struct sockaddr *dst,
SCTP_LTRACE_ERR_RET_PKT(mout, NULL, NULL, NULL, SCTP_FROM_SCTP_OUTPUT, EFAULT);
return;
}
SCTPDBG(SCTP_DEBUG_OUTPUT3, "return from send is %d\n", ret);
SCTP_STAT_INCR(sctps_sendpackets);
SCTP_STAT_INCR_COUNTER64(sctps_outpackets);
SCTP_STAT_INCR_COUNTER64(sctps_outcontrolchunks);
if (ret) {
SCTP_STAT_INCR(sctps_senderrors);
}
return;
}