Date: Wed, 3 Aug 2011 10:00:30 GMT From: dfilter@FreeBSD.ORG (dfilter service) To: freebsd-bugs@FreeBSD.org Subject: Re: bin/158431: commit references a PR Message-ID: <201108031000.p73A0UDs084579@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
The following reply was made to PR bin/158431; it has been noted by GNATS. From: dfilter@FreeBSD.ORG (dfilter service) To: bug-followup@FreeBSD.org Cc: Subject: Re: bin/158431: commit references a PR Date: Wed, 3 Aug 2011 09:56:08 +0000 (UTC) Author: avg Date: Wed Aug 3 09:55:59 2011 New Revision: 224632 URL: http://svn.freebsd.org/changeset/base/224632 Log: fix a serious bug in libproc's proc_attach proc_attach always frees any struct proc_handle data that it allocates, but that is supposed to be done only in error conditions. PR: bin/158431 Approved by: re (kib) MFC after: 1 week Modified: head/lib/libproc/proc_create.c Modified: head/lib/libproc/proc_create.c ============================================================================== --- head/lib/libproc/proc_create.c Wed Aug 3 09:42:48 2011 (r224631) +++ head/lib/libproc/proc_create.c Wed Aug 3 09:55:59 2011 (r224632) @@ -79,12 +79,11 @@ proc_attach(pid_t pid, int flags, struct else phdl->status = PS_STOP; +out: if (error) proc_free(phdl); else *pphdl = phdl; -out: - proc_free(phdl); return (error); } _______________________________________________ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to "svn-src-all-unsubscribe@freebsd.org"
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201108031000.p73A0UDs084579>