Date: Mon, 10 Oct 2011 12:28:47 +0000 (UTC) From: Michael Tuexen <tuexen@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r226203 - head/sys/netinet Message-ID: <201110101228.p9ACSlOq060152@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: tuexen Date: Mon Oct 10 12:28:47 2011 New Revision: 226203 URL: http://svn.freebsd.org/changeset/base/226203 Log: When moving an stcb to a new inp and we copy over the list of bound addresses, update the last used address pointer. If not, it might result in a crash if the old inp goes away. MFC after: 3 days. Modified: head/sys/netinet/sctp_pcb.c Modified: head/sys/netinet/sctp_pcb.c ============================================================================== --- head/sys/netinet/sctp_pcb.c Mon Oct 10 12:27:40 2011 (r226202) +++ head/sys/netinet/sctp_pcb.c Mon Oct 10 12:28:47 2011 (r226203) @@ -2786,6 +2786,9 @@ sctp_move_pcb_and_assoc(struct sctp_inpc LIST_INSERT_HEAD(&new_inp->sctp_addr_list, laddr, sctp_nxt_addr); new_inp->laddr_count++; + if (oladdr == stcb->asoc.last_used_address) { + stcb->asoc.last_used_address = laddr; + } } } /*
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201110101228.p9ACSlOq060152>