Bluetooth: AT: use explicit unsigned char to avoid array subscript error
If we use newlib the isdigit (and other similar functions) return an error as char can possibly be viewed as signed: usr/include/ctype.h:57:54: error: array subscript has type ‘char’ [-Werror=char-subscripts] #define __ctype_lookup(__c) ((__ctype_ptr__+sizeof(""[__c]))[(int)(__c)]) Being explicit about the char being unsigned char deals with this. Change-Id: I348189e1df11a1fcc58e5810b010b602fd2df33e Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
This commit is contained in:
parent
8f9776073f
commit
819d3ae9c9
1 changed files with 1 additions and 1 deletions
|
@ -89,7 +89,7 @@ typedef int (*handle_cmd_input_t)(struct at_client *at, struct net_buf *buf,
|
||||||
enum at_cmd_type type);
|
enum at_cmd_type type);
|
||||||
|
|
||||||
struct at_client {
|
struct at_client {
|
||||||
char *buf;
|
unsigned char *buf;
|
||||||
uint8_t pos;
|
uint8_t pos;
|
||||||
uint8_t buf_max_len;
|
uint8_t buf_max_len;
|
||||||
uint8_t state;
|
uint8_t state;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue