summaryrefslogtreecommitdiffstats
path: root/cddl/contrib/opensolaris/lib/libdtrace/common/dt_printf.c
diff options
context:
space:
mode:
authorpfg <pfg@FreeBSD.org>2013-07-28 00:45:20 +0000
committerpfg <pfg@FreeBSD.org>2013-07-28 00:45:20 +0000
commit46097436dce0630481061f04e049041976f3e295 (patch)
tree826c16a4321d19d6fd89afb4e5b9ce87a74528d3 /cddl/contrib/opensolaris/lib/libdtrace/common/dt_printf.c
parent9932d6357cd2745b8b313b513e4c8711a63cb77c (diff)
parent455309093315aa6181951cba3a699d09aca5ba5d (diff)
downloadFreeBSD-src-46097436dce0630481061f04e049041976f3e295.zip
FreeBSD-src-46097436dce0630481061f04e049041976f3e295.tar.gz
DTrace: re-merge remainder of r249367 (original from Illumos).
Bring back some important fixes from Illumos: 3022 DTrace: keys should not affect the sort order when sorting by value 3023 it should be possible to dereference dynamic variables 3024 D integer narrowing needs some work We particularly avoid the LD_NOLAZYLOAD changes that Illumos made as those don't apply to FreeBSD and were causing problems in interactive mode. Illumos Revision: 13758:23432da34147 Reference: https://www.illumos.org/issues/3022 https://www.illumos.org/issues/3023 https://www.illumos.org/issues/3024 MFC after: 1 month Tested by: markj
Diffstat (limited to 'cddl/contrib/opensolaris/lib/libdtrace/common/dt_printf.c')
-rw-r--r--cddl/contrib/opensolaris/lib/libdtrace/common/dt_printf.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/cddl/contrib/opensolaris/lib/libdtrace/common/dt_printf.c b/cddl/contrib/opensolaris/lib/libdtrace/common/dt_printf.c
index 51f87b0..24682b2 100644
--- a/cddl/contrib/opensolaris/lib/libdtrace/common/dt_printf.c
+++ b/cddl/contrib/opensolaris/lib/libdtrace/common/dt_printf.c
@@ -22,6 +22,7 @@
/*
* Copyright (c) 2003, 2010, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2011, Joyent, Inc. All rights reserved.
+ * Copyright (c) 2012 by Delphix. All rights reserved.
*/
#if defined(sun)
@@ -161,7 +162,7 @@ static int
pfcheck_dint(dt_pfargv_t *pfv, dt_pfargd_t *pfd, dt_node_t *dnp)
{
if (dnp->dn_flags & DT_NF_SIGNED)
- pfd->pfd_flags |= DT_PFCONV_SIGNED;
+ pfd->pfd_fmt[strlen(pfd->pfd_fmt) - 1] = 'i';
else
pfd->pfd_fmt[strlen(pfd->pfd_fmt) - 1] = 'u';
@@ -664,7 +665,7 @@ static const dt_pfconv_t _dtrace_conversions[] = {
{ "hu", "u", "unsigned short", pfcheck_type, pfprint_uint },
{ "hx", "x", "short", pfcheck_xshort, pfprint_uint },
{ "hX", "X", "short", pfcheck_xshort, pfprint_uint },
-{ "i", "i", pfproto_xint, pfcheck_dint, pfprint_dint },
+{ "i", "i", pfproto_xint, pfcheck_xint, pfprint_sint },
{ "I", "s", pfproto_cstr, pfcheck_str, pfprint_inetaddr },
{ "k", "s", "stack", pfcheck_stack, pfprint_stack },
{ "lc", "lc", "int", pfcheck_type, pfprint_sint }, /* a.k.a. wint_t */
OpenPOWER on IntegriCloud