Date: Wed, 25 Jul 2012 12:06:52 +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-8@freebsd.org Subject: svn commit: r238768 - stable/8/sys/dev/mps Message-ID: <201207251206.q6PC6qIx055705@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: brueffer Date: Wed Jul 25 12:06:52 2012 New Revision: 238768 URL: http://svn.freebsd.org/changeset/base/238768 Log: MFC: r238574 Fix a small memory leak in mpssas_get_sata_identify(). The change has been submitted upstream as well. Modified: stable/8/sys/dev/mps/mps_sas_lsi.c Directory Properties: stable/8/sys/ (props changed) stable/8/sys/dev/ (props changed) Modified: stable/8/sys/dev/mps/mps_sas_lsi.c ============================================================================== --- stable/8/sys/dev/mps/mps_sas_lsi.c Wed Jul 25 11:50:36 2012 (r238767) +++ stable/8/sys/dev/mps/mps_sas_lsi.c Wed Jul 25 12:06:52 2012 (r238768) @@ -796,8 +796,10 @@ mpssas_get_sata_identify(struct mps_soft if (!buffer) return ENOMEM; - if ((cm = mps_alloc_command(sc)) == NULL) + if ((cm = mps_alloc_command(sc)) == NULL) { + free(buffer, M_MPT2); return (EBUSY); + } mpi_request = (MPI2_SATA_PASSTHROUGH_REQUEST *)cm->cm_req; bzero(mpi_request,sizeof(MPI2_SATA_PASSTHROUGH_REQUEST)); mpi_request->Function = MPI2_FUNCTION_SATA_PASSTHROUGH;
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201207251206.q6PC6qIx055705>