提交 abcb0506 编写于 作者: mysterywolf's avatar mysterywolf

[libc][iar][gcc] 优化remove函数

上级 f0805a79
......@@ -16,9 +16,9 @@
#pragma module_name = "?remove"
int remove(const char *val)
{
#ifdef RT_USING_DFS
dfs_file_unlink(val);
#ifndef RT_USING_DFS
return -1;
#else
return unlink(filename);
#endif
return 0;
}
......@@ -196,12 +196,9 @@ int
_unlink_r(struct _reent *ptr, const char *file)
{
#ifndef RT_USING_DFS
return 0;
return -1;
#else
int rc;
rc = unlink(file);
return rc;
return unlink(file);
#endif
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册