aboutsummaryrefslogtreecommitdiff
path: root/gdb/arc-tdep.c
diff options
context:
space:
mode:
authorAnton Kolesov <Anton.Kolesov@synopsys.com>2016-09-22 13:29:43 +0300
committerAnton Kolesov <Anton.Kolesov@synopsys.com>2016-09-22 14:26:44 +0300
commitfa42dd2e8328560e65c888277ab146810c1763a8 (patch)
treec9a1bcbc83ed6ed482c9835b0e991152a83ff1df /gdb/arc-tdep.c
parent870dd155d688fec15d61eb1fe7ef36bd36791dd4 (diff)
downloadgdb-fa42dd2e8328560e65c888277ab146810c1763a8.zip
gdb-fa42dd2e8328560e65c888277ab146810c1763a8.tar.gz
gdb-fa42dd2e8328560e65c888277ab146810c1763a8.tar.bz2
arc: Fix ARI warning for printf(%p)
Replace printf ("%p") with printf ("%s", host_address_to_string ()). Printing host addrss might make sense here because pointers can be null and this would affect how function behaves. This particular warning is printed only when option -Wari is passed to contrib/ari/gdb_ari.sh gdb/ChangeLog: * arc-tdep.c: Fix ARI warning for printf(%p).
Diffstat (limited to 'gdb/arc-tdep.c')
-rw-r--r--gdb/arc-tdep.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/gdb/arc-tdep.c b/gdb/arc-tdep.c
index 6048ad6..7bb93ad 100644
--- a/gdb/arc-tdep.c
+++ b/gdb/arc-tdep.c
@@ -574,8 +574,9 @@ arc_return_value (struct gdbarch *gdbarch, struct value *function,
|| TYPE_LENGTH (valtype) > 2 * ARC_REGISTER_SIZE);
if (arc_debug)
- debug_printf ("arc: return_value (readbuf = %p, writebuf = %p)\n",
- readbuf, writebuf);
+ debug_printf ("arc: return_value (readbuf = %s, writebuf = %s)\n",
+ host_address_to_string (readbuf),
+ host_address_to_string (writebuf));
if (writebuf != NULL)
{