diff options
author | Michael Tuexen <tuexen@FreeBSD.org> | 2018-05-21 14:52:18 +0000 |
---|---|---|
committer | Michael Tuexen <tuexen@FreeBSD.org> | 2018-05-21 14:52:18 +0000 |
commit | d3132db2b551e8286e0ebe214e62a13fc3554f86 (patch) | |
tree | 160e8b6e8e528d18af7ec8044046052bc71ea45d /sys/netinet/sctp_output.c | |
parent | 95844fce7d99ce2074def1fd7627af1171c78fdd (diff) | |
download | src-d3132db2b551e8286e0ebe214e62a13fc3554f86.tar.gz src-d3132db2b551e8286e0ebe214e62a13fc3554f86.zip |
Do the appropriate accounting when ip_output() fails.
Notes
Notes:
svn path=/head/; revision=333980
Diffstat (limited to 'sys/netinet/sctp_output.c')
-rw-r--r-- | sys/netinet/sctp_output.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/sys/netinet/sctp_output.c b/sys/netinet/sctp_output.c index 68e0f324b6d7..31d9304a7ef5 100644 --- a/sys/netinet/sctp_output.c +++ b/sys/netinet/sctp_output.c @@ -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; } |