Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 8 May 2014 03:43:18 +0000 (UTC)
From:      Mark Johnston <markj@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r265631 - head/cddl/contrib/opensolaris/lib/libdtrace/common
Message-ID:  <201405080343.s483hIpV062917@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: markj
Date: Thu May  8 03:43:18 2014
New Revision: 265631
URL: http://svnweb.freebsd.org/changeset/base/265631

Log:
  Re-apply r248644. This fixes an annoying problem which caused dtrace -c to
  fail to attach to stripped binaries. With the _r_debug_postinit symbol,
  dtrace(1) can now set a breakpoint in the victim process after it has
  registered its DOF table(s) with the kernel. r_debug_state cannot be used
  for this purpose since it is called before DOF is made available, in which
  case dtrace(1) cannot create USDT probes before the program begins
  execution.
  
  MFC after:	2 weeks

Modified:
  head/cddl/contrib/opensolaris/lib/libdtrace/common/dt_open.c

Modified: head/cddl/contrib/opensolaris/lib/libdtrace/common/dt_open.c
==============================================================================
--- head/cddl/contrib/opensolaris/lib/libdtrace/common/dt_open.c	Thu May  8 03:33:54 2014	(r265630)
+++ head/cddl/contrib/opensolaris/lib/libdtrace/common/dt_open.c	Thu May  8 03:43:18 2014	(r265631)
@@ -1138,7 +1138,7 @@ alloc:
 #if defined(sun)
 	dtp->dt_prcmode = DT_PROC_STOP_PREINIT;
 #else
-	dtp->dt_prcmode = DT_PROC_STOP_MAIN;
+	dtp->dt_prcmode = DT_PROC_STOP_POSTINIT;
 #endif
 	dtp->dt_linkmode = DT_LINK_KERNEL;
 	dtp->dt_linktype = DT_LTYP_ELF;



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