Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S964997AbWIFXIy (ORCPT ); Wed, 6 Sep 2006 19:08:54 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S964977AbWIFXC7 (ORCPT ); Wed, 6 Sep 2006 19:02:59 -0400 Received: from mail.kroah.org ([69.55.234.183]:50636 "EHLO perch.kroah.org") by vger.kernel.org with ESMTP id S964971AbWIFXCE (ORCPT ); Wed, 6 Sep 2006 19:02:04 -0400 Date: Wed, 6 Sep 2006 15:56:52 -0700 From: Greg KH To: linux-kernel@vger.kernel.org, stable@kernel.org Cc: Justin Forbes , Zwane Mwaikambo , "Theodore Ts'o" , Randy Dunlap , Dave Jones , Chuck Wolber , Chris Wedgwood , torvalds@osdl.org, akpm@osdl.org, alan@lxorguk.ukuu.org.uk, Sridhar Samudrala , "David S. Miller" Subject: [patch 19/37] SCTP: Fix sctp_primitive_ABORT() call in sctp_close(). Message-ID: <20060906225652.GT15922@kroah.com> References: <20060906224631.999046890@quad.kroah.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline; filename="sctp-fix-sctp_primitive_abort-call-in-sctp_close.patch" In-Reply-To: <20060906225444.GA15922@kroah.com> User-Agent: Mutt/1.5.13 (2006-08-11) Sender: linux-kernel-owner@vger.kernel.org X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1252 Lines: 42 -stable review patch. If anyone has any objections, please let us know. ------------------ From: Sridhar Samudrala With the recent fix, the callers of sctp_primitive_ABORT() need to create an ABORT chunk and pass it as an argument rather than msghdr that was passed earlier. Signed-off-by: Sridhar Samudrala Signed-off-by: David S. Miller --- net/sctp/socket.c | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) --- linux-2.6.17.11.orig/net/sctp/socket.c +++ linux-2.6.17.11/net/sctp/socket.c @@ -1246,9 +1246,13 @@ SCTP_STATIC void sctp_close(struct sock } } - if (sock_flag(sk, SOCK_LINGER) && !sk->sk_lingertime) - sctp_primitive_ABORT(asoc, NULL); - else + if (sock_flag(sk, SOCK_LINGER) && !sk->sk_lingertime) { + struct sctp_chunk *chunk; + + chunk = sctp_make_abort_user(asoc, NULL, 0); + if (chunk) + sctp_primitive_ABORT(asoc, chunk); + } else sctp_primitive_SHUTDOWN(asoc, NULL); } -- - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/