From owner-svn-src-stable-10@FreeBSD.ORG Wed Aug 13 11:11:27 2014 Return-Path: Delivered-To: svn-src-stable-10@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id C5038EF; Wed, 13 Aug 2014 11:11:27 +0000 (UTC) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id B0A1C2721; Wed, 13 Aug 2014 11:11:27 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.9/8.14.9) with ESMTP id s7DBBRms062420; Wed, 13 Aug 2014 11:11:27 GMT (envelope-from trasz@FreeBSD.org) Received: (from trasz@localhost) by svn.freebsd.org (8.14.9/8.14.9/Submit) id s7DBBRUD062419; Wed, 13 Aug 2014 11:11:27 GMT (envelope-from trasz@FreeBSD.org) Message-Id: <201408131111.s7DBBRUD062419@svn.freebsd.org> X-Authentication-Warning: svn.freebsd.org: trasz set sender to trasz@FreeBSD.org using -f From: Edward Tomasz Napierala Date: Wed, 13 Aug 2014 11:11:27 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r269925 - stable/10/sys/dev/iscsi X-SVN-Group: stable-10 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-10@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: SVN commit messages for only the 10-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 13 Aug 2014 11:11:27 -0000 Author: trasz Date: Wed Aug 13 11:11:27 2014 New Revision: 269925 URL: http://svnweb.freebsd.org/changeset/base/269925 Log: MFC r269197: Fix potential double free that could happen after connection error. Modified: stable/10/sys/dev/iscsi/icl.c Directory Properties: stable/10/ (props changed) Modified: stable/10/sys/dev/iscsi/icl.c ============================================================================== --- stable/10/sys/dev/iscsi/icl.c Wed Aug 13 09:34:33 2014 (r269924) +++ stable/10/sys/dev/iscsi/icl.c Wed Aug 13 11:11:27 2014 (r269925) @@ -669,7 +669,10 @@ icl_conn_receive_pdu(struct icl_conn *ic } if (error != 0) { - icl_pdu_free(request); + /* + * Don't free the PDU; it's pointed to by ic->ic_receive_pdu + * and will get freed in icl_conn_close(). + */ icl_conn_fail(ic); }