diff options
| author | Shell <[email protected]> | 2023-03-13 19:09:34 +0800 |
|---|---|---|
| committer | GitHub <[email protected]> | 2023-03-13 19:09:34 +0800 |
| commit | fcc01a617d62d72ba282580d4810d23ec0a1325f (patch) | |
| tree | 1318aa47cb3fea3d01fcebdba8114a6a75f5c5d5 /components/dfs/src | |
| parent | 34bf77b8e35489858901af055202bdb30b047e0b (diff) | |
[rt-smart] Fix return value in syscall (#7045)
* [timer] fix sys return value to avoid outdated errno
* [rtdef] add wrap to stringify
* [syscall] return value in rt errno should be recycle immediately after call to posix layer
* [syscall] return type of syscall should be long
errno should be recycle immediately after call to rt posix layer to avoid
outdated value
* [format] move prototype to header file
* [fix] futex definition conflict
Diffstat (limited to 'components/dfs/src')
| -rw-r--r-- | components/dfs/src/dfs.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/components/dfs/src/dfs.c b/components/dfs/src/dfs.c index 5ec2c7bab9..e2928f5e1b 100644 --- a/components/dfs/src/dfs.c +++ b/components/dfs/src/dfs.c @@ -374,7 +374,7 @@ void fd_release(int fd) fdt_fd_release(fdt, fd); } -int sys_dup(int oldfd) +rt_err_t sys_dup(int oldfd) { int newfd = -1; struct dfs_fdtable *fdt = NULL; @@ -466,7 +466,7 @@ int fd_is_open(const char *pathname) return -1; } -int sys_dup2(int oldfd, int newfd) +rt_err_t sys_dup2(int oldfd, int newfd) { struct dfs_fdtable *fdt = NULL; int ret = 0; |
