From 91ce0439f562f76b6f7895afd37116f6fed82ae9 Mon Sep 17 00:00:00 2001 From: Jukka Taimisto Date: Tue, 20 Jan 2015 11:23:31 +0200 Subject: [PATCH] profiles/gap: Change len parameter of name2utf8() to uint16_t When device name is read its length is of type uint16_t, change the type of length parameter of name2utf8() to uint16_t to avoid unnecessary truncation. --- profiles/gap/gas.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/profiles/gap/gas.c b/profiles/gap/gas.c index 90b2b4f2e..f737949ee 100644 --- a/profiles/gap/gas.c +++ b/profiles/gap/gas.c @@ -73,7 +73,7 @@ static int cmp_device(gconstpointer a, gconstpointer b) return gas->device == device ? 0 : -1; } -static char *name2utf8(const uint8_t *name, uint8_t len) +static char *name2utf8(const uint8_t *name, uint16_t len) { char utf8_name[HCI_MAX_NAME_LENGTH + 2]; int i; -- 2.47.3