Date: Sat, 31 Oct 2009 11:23:54 +0000 (UTC) From: Christian Brueffer <brueffer@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-7@freebsd.org Subject: svn commit: r198713 - in stable/7/sys: . cam/scsi contrib/pf Message-ID: <200910311123.n9VBNsRk087644@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: brueffer Date: Sat Oct 31 11:23:54 2009 New Revision: 198713 URL: http://svn.freebsd.org/changeset/base/198713 Log: MFC: 198356 Fix a memory leak in an error case. Modified: stable/7/sys/ (props changed) stable/7/sys/cam/scsi/scsi_low.c stable/7/sys/contrib/pf/ (props changed) Modified: stable/7/sys/cam/scsi/scsi_low.c ============================================================================== --- stable/7/sys/cam/scsi/scsi_low.c Sat Oct 31 11:21:45 2009 (r198712) +++ stable/7/sys/cam/scsi/scsi_low.c Sat Oct 31 11:23:54 2009 (r198713) @@ -638,7 +638,10 @@ scsi_low_attach_xs(slp) return ENOMEM; splp = SCSI_LOW_MALLOC(sizeof(*splp)); if (splp == NULL) + { + SCSI_LOW_FREE(sap); return ENOMEM; + } SCSI_LOW_BZERO(sap, sizeof(*sap)); SCSI_LOW_BZERO(splp, sizeof(*splp));
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200910311123.n9VBNsRk087644>