gmio_stl: use snprintf() instead of sprintf() in stla_error_token_expected()
This commit is contained in:
parent
37c4a2a576
commit
480c0fbf11
@ -370,10 +370,10 @@ void stla_error_token_expected(
|
||||
struct gmio_stla_parse_data* data, enum gmio_stla_token token)
|
||||
{
|
||||
char msg[256] = {0};
|
||||
sprintf(msg,
|
||||
"expected <%s>, got <%s>",
|
||||
stla_token_to_string(token),
|
||||
stla_token_to_string(data->token));
|
||||
snprintf(msg, sizeof(msg),
|
||||
"expected <%s>, got <%s>",
|
||||
stla_token_to_string(token),
|
||||
stla_token_to_string(data->token));
|
||||
stla_error_msg(data, msg);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user