[armlibc] 修复AC6更新至6.19后_sys_tmpnam()函数编译报错, 直接从主分支的 commit #cef57d0 rebase过来。 (#9265)
[armlibc] 修复AC6更新至6.19后_sys_tmpnam()函数编译报错 (#6647) * [armlibc] 修复AC6更新至6.19后_sys_tmpnam()函数编译报错 Co-authored-by: wdfk-prog <1425075683@qq.com> Co-authored-by: Man, Jianting (Meco) <920369182@qq.com>
This commit is contained in:
parent
9376074b15
commit
7aa109ced8
|
@ -282,11 +282,18 @@ int _sys_seek(FILEHANDLE fh, long pos)
|
||||||
/**
|
/**
|
||||||
* used by tmpnam() or tmpfile()
|
* used by tmpnam() or tmpfile()
|
||||||
*/
|
*/
|
||||||
|
#if __ARMCC_VERSION >= 6190000
|
||||||
|
void _sys_tmpnam(char *name, int fileno, unsigned maxlength)
|
||||||
|
{
|
||||||
|
rt_snprintf(name, maxlength, "tem%03d", fileno);
|
||||||
|
}
|
||||||
|
#else
|
||||||
int _sys_tmpnam(char *name, int fileno, unsigned maxlength)
|
int _sys_tmpnam(char *name, int fileno, unsigned maxlength)
|
||||||
{
|
{
|
||||||
rt_snprintf(name, maxlength, "tem%03d", fileno);
|
rt_snprintf(name, maxlength, "tem%03d", fileno);
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
#endif /* __ARMCC_VERSION >= 6190000 */
|
||||||
|
|
||||||
char *_sys_command_string(char *cmd, int len)
|
char *_sys_command_string(char *cmd, int len)
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in New Issue