diff options
author | Tom Tromey <tromey@redhat.com> | 2014-01-18 19:34:15 -0700 |
---|---|---|
committer | Tom Tromey <tromey@redhat.com> | 2014-02-12 09:59:18 -0700 |
commit | e9371aff2d8c31adf23483aebe85018e11f534f3 (patch) | |
tree | 239a27ae3dcc7f1a7fe4c20e35d947359e0566aa /gdb/gdbserver/tracepoint.c | |
parent | 971dc0b89de28feaa5efade1f1f8675be223fabd (diff) | |
download | gdb-e9371aff2d8c31adf23483aebe85018e11f534f3.zip gdb-e9371aff2d8c31adf23483aebe85018e11f534f3.tar.gz gdb-e9371aff2d8c31adf23483aebe85018e11f534f3.tar.bz2 |
replace convert_int_to_ascii with bin2hex
convert_int_to_ascii is identical to bin2hex. This removes the
former. In this case I made the choice of which to keep on the basis
that I consider the name bin2hex to be superior to
convert_int_to_ascii.
2014-02-12 Tom Tromey <tromey@redhat.com>
* common/rsp-low.h (convert_int_to_ascii): Don't declare.
* common/rsp-low.c (convert_int_to_ascii): Remove.
2014-02-12 Tom Tromey <tromey@redhat.com>
* ax.c (gdb_unparse_agent_expr): Use bin2hex, not
convert_int_to_ascii.
* regcache.c (registers_to_string, collect_register_as_string):
Likewise.
* remote-utils.c (look_up_one_symbol, relocate_instruction):
Likewise.
* server.c (process_serial_event): Likewise.
* tracepoint.c (cmd_qtstatus, response_source, response_tsv)
(cmd_qtbuffer, cstr_to_hexstr): Likewise.
Diffstat (limited to 'gdb/gdbserver/tracepoint.c')
-rw-r--r-- | gdb/gdbserver/tracepoint.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/gdb/gdbserver/tracepoint.c b/gdb/gdbserver/tracepoint.c index 3ae3bdd..df32005 100644 --- a/gdb/gdbserver/tracepoint.c +++ b/gdb/gdbserver/tracepoint.c @@ -3663,7 +3663,7 @@ cmd_qtstatus (char *packet) p = stop_reason_rsp = alloca (strlen ("terror:") + hexstr_len + 1); strcpy (p, "terror:"); p += strlen (p); - convert_int_to_ascii ((gdb_byte *) result_name, p, strlen (result_name)); + bin2hex ((gdb_byte *) result_name, p, strlen (result_name)); } /* If this was a forced stop, include any stop note that was supplied. */ @@ -3782,7 +3782,7 @@ response_source (char *packet, len = strlen (src->str); buf = alloca (len * 2 + 1); - convert_int_to_ascii ((gdb_byte *) src->str, buf, len); + bin2hex ((gdb_byte *) src->str, buf, len); sprintf (packet, "Z%x:%s:%s:%x:%x:%s", tpoint->number, paddress (tpoint->address), @@ -3871,7 +3871,7 @@ response_tsv (char *packet, struct trace_state_variable *tsv) { namelen = strlen (tsv->name); buf = alloca (namelen * 2 + 1); - convert_int_to_ascii ((gdb_byte *) tsv->name, buf, namelen); + bin2hex ((gdb_byte *) tsv->name, buf, namelen); } sprintf (packet, "%x:%s:%x:%s", tsv->number, phex_nz (tsv->initial_value, 0), @@ -4041,7 +4041,7 @@ cmd_qtbuffer (char *own_buf) if (num >= (PBUFSIZ - 16) / 2 ) num = (PBUFSIZ - 16) / 2; - convert_int_to_ascii (tbp, own_buf, num); + bin2hex (tbp, own_buf, num); } static void @@ -6930,7 +6930,7 @@ cstr_to_hexstr (const char *str) { int len = strlen (str); char *hexstr = xmalloc (len * 2 + 1); - convert_int_to_ascii ((gdb_byte *) str, hexstr, len); + bin2hex ((gdb_byte *) str, hexstr, len); return hexstr; } |