summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMarcel Holtmann <marcel@holtmann.org>2003-11-20 08:50:42 +0000
committerMarcel Holtmann <marcel@holtmann.org>2003-11-20 08:50:42 +0000
commit6b5b6093a75df05d27571d192d4ef2fb56bfc6e2 (patch)
treeb111b21b1a15decd62691dba6ab4c6e7bbe4bbd3
parentaac33d6b2e0c3c7b021478feb320afd8c812bda9 (diff)
Fix lmp_featurestostr()
-rw-r--r--src/hci.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/src/hci.c b/src/hci.c
index 61bdd1a6..8100d227 100644
--- a/src/hci.c
+++ b/src/hci.c
@@ -293,7 +293,7 @@ int lmp_strtover(char *str, unsigned int *ver)
}
/* LMP features mapping */
-hci_map lmp_features_map[][9] = {
+hci_map lmp_features_map[8][9] = {
{ /* byte 0 */
{ "<3-slot packets>", LMP_3SLOT },
{ "<5-slot packets>", LMP_5SLOT },
@@ -351,7 +351,6 @@ hci_map lmp_features_map[][9] = {
{ "<extended features>",LMP_EXT_FEAT },
{ NULL }
},
- {{ NULL }}
};
char *lmp_featurestostr(uint8_t *features, char *pref, int width)
@@ -367,7 +366,7 @@ char *lmp_featurestostr(uint8_t *features, char *pref, int width)
if (pref)
ptr += sprintf(ptr, "%s", pref);
- for(i=0, w=0; lmp_features_map[i][0].str; i++) {
+ for(i=0, w=0; i<8; i++) {
hci_map *m;
m = lmp_features_map[i];
@@ -381,7 +380,7 @@ char *lmp_featurestostr(uint8_t *features, char *pref, int width)
m++;
}
}
-
+
return str;
}