Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 25 May 2012 23:24:17 +0000 (UTC)
From:      Ryan Stone <rstone@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: r236030 - stable/8/sys/kern
Message-ID:  <201205252324.q4PNOHSw039123@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: rstone
Date: Fri May 25 23:24:16 2012
New Revision: 236030
URL: http://svn.freebsd.org/changeset/base/236030

Log:
  MFC r227342
  
   The in-kernel CTF parser caches the result of its first attempt to parse
   CTF data from a module.  On subsequent attempts to retrieve CTF data for
   a module, return an error if there no CTF data.
  
   This fixes a panic if you try to enable fbt probes on a module without CTF
   data twice.
  
  Submitted by:	Paul Ambrose (ambrosehua AT gmail DOT com)

Modified:
  stable/8/sys/kern/kern_ctf.c
Directory Properties:
  stable/8/sys/   (props changed)

Modified: stable/8/sys/kern/kern_ctf.c
==============================================================================
--- stable/8/sys/kern/kern_ctf.c	Fri May 25 22:42:21 2012	(r236029)
+++ stable/8/sys/kern/kern_ctf.c	Fri May 25 23:24:16 2012	(r236030)
@@ -90,7 +90,7 @@ link_elf_ctf_get(linker_file_t lf, linke
 	 * ctfcnt to -1. See below.
 	 */
 	if (ef->ctfcnt < 0)
-		return (0);
+		return (EFTYPE);
 
 	/* Now check if we've already loaded the CTF data.. */
 	if (ef->ctfcnt > 0) {



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201205252324.q4PNOHSw039123>