From ce1d6b0efafff8148d0526190169631dd208a040 Mon Sep 17 00:00:00 2001 From: "Bjoern A. Zeeb" Date: Sat, 23 Jan 2016 12:50:02 +0000 Subject: [PATCH] Use sctp_asconf_iterator_end() rather than doing the cleanup manually. Sponsored by: The FreeBSD Foundation --- sys/netinet/sctp_asconf.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/sys/netinet/sctp_asconf.c b/sys/netinet/sctp_asconf.c index 2f82b75158b4..328b3b5bb504 100644 --- a/sys/netinet/sctp_asconf.c +++ b/sys/netinet/sctp_asconf.c @@ -3281,10 +3281,7 @@ sctp_addr_mgmt_ep_sa(struct sctp_inpcb *inp, struct sockaddr *sa, if (ret) { SCTP_PRINTF("Failed to initiate iterator for addr_mgmt_ep_sa\n"); SCTP_LTRACE_ERR_RET(inp, NULL, NULL, SCTP_FROM_SCTP_ASCONF, EFAULT); - atomic_add_int(&ifa->refcount, -1); - SCTP_DECR_LADDR_COUNT(); - SCTP_ZONE_FREE(SCTP_BASE_INFO(ipi_zone_laddr), wi); - SCTP_FREE(asc, SCTP_M_ASC_IT); + sctp_asconf_iterator_end(asc); return (EFAULT); } }