mirror of
https://github.com/apache/nuttx.git
synced 2025-01-13 08:38:38 +08:00
libs/libc/stdio: using sprintf to instead itoa
itoa isn't posix function, the standard stdlib file exclude it. Signed-off-by: dongjiuzhu1 <dongjiuzhu1@xiaomi.com>
This commit is contained in:
parent
88da2b4adb
commit
47eec633a0
1 changed files with 1 additions and 1 deletions
|
@ -164,7 +164,7 @@ int lib_bsprintf(FAR struct lib_outstream_s *s, FAR const IPTR char *fmt,
|
|||
}
|
||||
else if (c == '*')
|
||||
{
|
||||
itoa(var->i, fmtstr + len - 1, 10);
|
||||
sprintf(fmtstr + len - 1, "%d", var->i);
|
||||
len = strlen(fmtstr);
|
||||
offset += sizeof(var->i);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue