diff options
author | Tom Tromey <tromey@redhat.com> | 2014-01-18 19:25:57 -0700 |
---|---|---|
committer | Tom Tromey <tromey@redhat.com> | 2014-02-12 09:59:16 -0700 |
commit | 0a822afbcdf6aee6c25a840e4785ad3af56a94fd (patch) | |
tree | 169393d7a5cc2a03aafa5c26ea3e4239c00a9386 /gdb/common/rsp-low.c | |
parent | 9f1b45b0da430a7a7abf9e54acbe6f2ef9d3a763 (diff) | |
download | gdb-0a822afbcdf6aee6c25a840e4785ad3af56a94fd.zip gdb-0a822afbcdf6aee6c25a840e4785ad3af56a94fd.tar.gz gdb-0a822afbcdf6aee6c25a840e4785ad3af56a94fd.tar.bz2 |
don't let hexify call strlen
hexify had the same issue as bin2hex; and the fix is the same.
2014-02-12 Tom Tromey <tromey@redhat.com>
* common/rsp-low.c (hexify): Never take strlen of argument.
2014-02-12 Tom Tromey <tromey@redhat.com>
* remote-utils.c (monitor_output): Pass explicit length to
hexify.
Diffstat (limited to 'gdb/common/rsp-low.c')
-rw-r--r-- | gdb/common/rsp-low.c | 4 |
1 files changed, 0 insertions, 4 deletions
diff --git a/gdb/common/rsp-low.c b/gdb/common/rsp-low.c index 7f0445c..fd6f563 100644 --- a/gdb/common/rsp-low.c +++ b/gdb/common/rsp-low.c @@ -177,10 +177,6 @@ hexify (char *hex, const char *bin, int count) { int i; - /* May use a length, or a nul-terminated string as input. */ - if (count == 0) - count = strlen (bin); - for (i = 0; i < count; i++) { *hex++ = tohex ((*bin >> 4) & 0xf); |