OSDN Git Service
(root)
/
android-x86
/
external-bluetooth-bluez.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
31324f4
)
monitor: Fix zero-length field handling in print_hex_field
author
Johan Hedberg
<johan.hedberg@intel.com>
Thu, 10 Oct 2013 11:49:09 +0000
(14:49 +0300)
committer
Johan Hedberg
<johan.hedberg@intel.com>
Thu, 10 Oct 2013 11:49:35 +0000
(14:49 +0300)
monitor/packet.c
patch
|
blob
|
history
diff --git
a/monitor/packet.c
b/monitor/packet.c
index
fae6161
..
9badfcd
100644
(file)
--- a/
monitor/packet.c
+++ b/
monitor/packet.c
@@
-1185,6
+1185,8
@@
static void print_hex_field(const char *label, const uint8_t *data,
char str[len * 2 + 1];
uint8_t i;
+ str[0] = '\0';
+
for (i = 0; i < len; i++)
sprintf(str + (i * 2), "%2.2x", data[i]);