tools/nxstyle: Add kbps to the while suffix list
and correct offset by 1 error Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
This commit is contained in:
parent
2976accd9f
commit
f905563cc9
@ -211,8 +211,11 @@ static const char *g_white_prefix[] =
|
||||
|
||||
static const char *g_white_suffix[] =
|
||||
{
|
||||
"kHz",
|
||||
/* Ref: include/nuttx/wireless/nrf24l01.h */
|
||||
|
||||
"Mbps",
|
||||
"kHz",
|
||||
"kbps",
|
||||
"us",
|
||||
NULL
|
||||
};
|
||||
@ -738,7 +741,7 @@ static bool white_list(const char *ident, int lineno)
|
||||
}
|
||||
|
||||
len2 = strlen(ident);
|
||||
while (!isalnum(ident[len2]))
|
||||
while (!isalnum(ident[len2 - 1]))
|
||||
{
|
||||
len2--;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user