Date: Sun, 13 Apr 2014 21:23:16 +0000 (UTC) From: Christian Brueffer <brueffer@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r264422 - head/sys/kern Message-ID: <201404132123.s3DLNGvJ048359@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: brueffer Date: Sun Apr 13 21:23:15 2014 New Revision: 264422 URL: http://svnweb.freebsd.org/changeset/base/264422 Log: Free buf after usage. CID: 1199377 Found with: Coverity Prevent(tm) MFC after: 1 week Modified: head/sys/kern/imgact_elf.c Modified: head/sys/kern/imgact_elf.c ============================================================================== --- head/sys/kern/imgact_elf.c Sun Apr 13 21:13:33 2014 (r264421) +++ head/sys/kern/imgact_elf.c Sun Apr 13 21:23:15 2014 (r264422) @@ -1746,8 +1746,10 @@ __elfN(note_threadmd)(void *arg, struct size = 0; __elfN(dump_thread)(td, buf, &size); KASSERT(*sizep == size, ("invalid size")); - if (size != 0 && sb != NULL) + if (size != 0 && sb != NULL) { sbuf_bcat(sb, buf, size); + free(buf, M_TEMP); + } *sizep = size; }
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201404132123.s3DLNGvJ048359>