From owner-svn-src-all@freebsd.org Tue May 10 07:52:18 2016 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 73FFEB356F7; Tue, 10 May 2016 07:52:18 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4B9C31CD8; Tue, 10 May 2016 07:52:18 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id u4A7qH7I030308; Tue, 10 May 2016 07:52:17 GMT (envelope-from bapt@FreeBSD.org) Received: (from bapt@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id u4A7qHmx030307; Tue, 10 May 2016 07:52:17 GMT (envelope-from bapt@FreeBSD.org) Message-Id: <201605100752.u4A7qHmx030307@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: bapt set sender to bapt@FreeBSD.org using -f From: Baptiste Daroussin Date: Tue, 10 May 2016 07:52:17 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r299343 - head/cddl/contrib/opensolaris/lib/libdtrace/common X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.22 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 10 May 2016 07:52:18 -0000 Author: bapt Date: Tue May 10 07:52:17 2016 New Revision: 299343 URL: https://svnweb.freebsd.org/changeset/base/299343 Log: Rename dprintf into dbg_printf to avoid collision with dprintf(3) When dprintf(3) in 2009 was added a _WITH_DPRINTF guard has also been added. This rename is made in preparation for the removal of this guard Modified: head/cddl/contrib/opensolaris/lib/libdtrace/common/drti.c Modified: head/cddl/contrib/opensolaris/lib/libdtrace/common/drti.c ============================================================================== --- head/cddl/contrib/opensolaris/lib/libdtrace/common/drti.c Tue May 10 07:50:57 2016 (r299342) +++ head/cddl/contrib/opensolaris/lib/libdtrace/common/drti.c Tue May 10 07:52:17 2016 (r299343) @@ -65,7 +65,7 @@ extern dof_hdr_t __SUNW_dof; /* DOF defi static boolean_t dof_init_debug = B_FALSE; /* From DTRACE_DOF_INIT_DEBUG */ static void -dprintf(int debug, const char *fmt, ...) +dbg_printf(int debug, const char *fmt, ...) { va_list ap; @@ -119,13 +119,13 @@ dtrace_dof_init(void) dof_init_debug = B_TRUE; if (dlinfo(RTLD_SELF, RTLD_DI_LINKMAP, &lmp) == -1 || lmp == NULL) { - dprintf(1, "couldn't discover module name or address\n"); + dbg_printf(1, "couldn't discover module name or address\n"); return; } #ifdef illumos if (dlinfo(RTLD_SELF, RTLD_DI_LMID, &lmid) == -1) { - dprintf(1, "couldn't discover link map ID\n"); + dbg_printf(1, "couldn't discover link map ID\n"); return; } #endif @@ -139,7 +139,7 @@ dtrace_dof_init(void) dof->dofh_ident[DOF_ID_MAG1] != DOF_MAG_MAG1 || dof->dofh_ident[DOF_ID_MAG2] != DOF_MAG_MAG2 || dof->dofh_ident[DOF_ID_MAG3] != DOF_MAG_MAG3) { - dprintf(0, ".SUNW_dof section corrupt\n"); + dbg_printf(0, ".SUNW_dof section corrupt\n"); return; } @@ -163,7 +163,7 @@ dtrace_dof_init(void) devnamep = p; if ((fd = open64(devnamep, O_RDWR)) < 0) { - dprintf(1, "failed to open helper device %s", devnamep); + dbg_printf(1, "failed to open helper device %s", devnamep); #ifdef illumos /* * If the device path wasn't explicitly set, try again with @@ -175,7 +175,7 @@ dtrace_dof_init(void) devnamep = olddevname; if ((fd = open64(devnamep, O_RDWR)) < 0) { - dprintf(1, "failed to open helper device %s", devnamep); + dbg_printf(1, "failed to open helper device %s", devnamep); return; } #else @@ -183,9 +183,9 @@ dtrace_dof_init(void) #endif } if ((gen = ioctl(fd, DTRACEHIOC_ADDDOF, &dh)) == -1) - dprintf(1, "DTrace ioctl failed for DOF at %p", dof); + dbg_printf(1, "DTrace ioctl failed for DOF at %p", dof); else { - dprintf(1, "DTrace ioctl succeeded for DOF at %p\n", dof); + dbg_printf(1, "DTrace ioctl succeeded for DOF at %p\n", dof); #ifdef __FreeBSD__ gen = dh.dofhp_gen; #endif @@ -206,14 +206,14 @@ dtrace_dof_fini(void) int fd; if ((fd = open64(devnamep, O_RDWR)) < 0) { - dprintf(1, "failed to open helper device %s", devnamep); + dbg_printf(1, "failed to open helper device %s", devnamep); return; } if ((gen = ioctl(fd, DTRACEHIOC_REMOVE, &gen)) == -1) - dprintf(1, "DTrace ioctl failed to remove DOF (%d)\n", gen); + dbg_printf(1, "DTrace ioctl failed to remove DOF (%d)\n", gen); else - dprintf(1, "DTrace ioctl removed DOF (%d)\n", gen); + dbg_printf(1, "DTrace ioctl removed DOF (%d)\n", gen); (void) close(fd); }