diff options
author | Jan Kratochvil <jan.kratochvil@redhat.com> | 2015-06-15 17:08:49 +0200 |
---|---|---|
committer | Jan Kratochvil <jan.kratochvil@redhat.com> | 2015-06-15 17:08:49 +0200 |
commit | 909c2cdaa78f5c33ce61a3b47e86f831025d0a02 (patch) | |
tree | 5172e07fec31ef80fcfc87f7261bee1c0942f644 /gdb/gdbserver | |
parent | 03aef70fecec83e109c65337a59600ad36def6bf (diff) | |
download | binutils-gdb-909c2cdaa78f5c33ce61a3b47e86f831025d0a02.tar.gz |
Merge multiple hex conversions
gdb/ChangeLog
2015-06-15 Aleksandar Ristovski <aristovski@qnx.com
Jan Kratochvil <jan.kratochvil@redhat.com>
Merge multiple hex conversions.
* monitor.c: Include rsp-low.h.
(fromhex): Remove definition.
gdb/gdbserver/ChangeLog
2015-06-15 Aleksandar Ristovski <aristovski@qnx.com
Jan Kratochvil <jan.kratochvil@redhat.com>
Merge multiple hex conversions.
* gdbreplay.c (tohex): Rename to 'fromhex'.
(logchar): Use fromhex.
Diffstat (limited to 'gdb/gdbserver')
-rw-r--r-- | gdb/gdbserver/ChangeLog | 7 | ||||
-rw-r--r-- | gdb/gdbserver/gdbreplay.c | 6 |
2 files changed, 10 insertions, 3 deletions
diff --git a/gdb/gdbserver/ChangeLog b/gdb/gdbserver/ChangeLog index 5d5f0a435af..c1d589ac3b2 100644 --- a/gdb/gdbserver/ChangeLog +++ b/gdb/gdbserver/ChangeLog @@ -1,3 +1,10 @@ +2015-06-15 Aleksandar Ristovski <aristovski@qnx.com + Jan Kratochvil <jan.kratochvil@redhat.com> + + Merge multiple hex conversions. + * gdbreplay.c (tohex): Rename to 'fromhex'. + (logchar): Use fromhex. + 2015-06-10 Jan Kratochvil <jan.kratochvil@redhat.com> * server.c (handle_qxfer_libraries): Set `version' attribute for diff --git a/gdb/gdbserver/gdbreplay.c b/gdb/gdbserver/gdbreplay.c index a02a824072b..79aa8aa8a85 100644 --- a/gdb/gdbserver/gdbreplay.c +++ b/gdb/gdbserver/gdbreplay.c @@ -259,7 +259,7 @@ remote_open (char *name) } static int -tohex (int ch) +fromhex (int ch) { if (ch >= '0' && ch <= '9') { @@ -322,11 +322,11 @@ logchar (FILE *fp) ch2 = fgetc (fp); fputc (ch2, stdout); fflush (stdout); - ch = tohex (ch2) << 4; + ch = fromhex (ch2) << 4; ch2 = fgetc (fp); fputc (ch2, stdout); fflush (stdout); - ch |= tohex (ch2); + ch |= fromhex (ch2); break; default: /* Treat any other char as just itself */ |