nuttx/libs/libc/unistd
Xiang Xiao e160bffe28 Remove all fclose with stdin, stdout and stderr
since it is wrong to close the builtin stream and specially note
https://pubs.opengroup.org/onlinepubs/9699919799/functions/fclose.html:

Since after the call to fclose() any use of stream results in
undefined behavior, fclose() should not be used on stdin, stdout,
or stderr except immediately before process termination (see XBD
Process Termination), so as to avoid triggering undefined behavior
in other standard interfaces that rely on these streams. If there
are any atexit() handlers registered by the application, such a
call to fclose() should not occur until the last handler is
finishing. Once fclose() has been used to close stdin, stdout, or
stderr, there is no standard way to reopen any of these streams.

and it is also unnecessary because the stream always get flushed.

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-10-29 20:43:50 +09:00
..
Kconfig Introduce CONFIG_DEFAULT_TASK_STACKSIZE 2020-03-26 22:30:13 -05:00
lib_access.c libc: Implement access function correctly 2020-09-22 10:30:36 +02:00
lib_alarm.c Change all files come from Xiaomi/Pinecone to Apache License 2.0 2020-08-22 17:37:21 -06:00
lib_chdir.c CONFIG_NFILE_DESCRIPTORS=0 can no longer be used to disable the file system. NuttX with no file system does not make sense. 2019-02-11 12:09:26 -06:00
lib_daemon.c Remove all fclose with stdin, stdout and stderr 2020-10-29 20:43:50 +09:00
lib_execl.c libc: Replace all malloc/free to lib_malloc/lib_free 2020-07-29 10:14:27 +01:00
lib_fstatvfs.c fs/vfs: Implement statvfs and fstatvfs 2020-07-13 20:25:03 +01:00
lib_futimens.c libs/libc/time: add stub for futimes/ns(2) 2020-09-19 03:20:09 -07:00
lib_futimes.c libs/libc/time: add stub for futimes/ns(2) 2020-09-19 03:20:09 -07:00
lib_getcwd.c libs/libc/unistd/lib_getcwd.c: remove stray sched_unlock(). Also fixes several typos. 2019-09-20 06:23:48 -06:00
lib_getegid.c libc/libc/unistd/: Add stubs for geteuid(), getegid(), seteuid(), and setegid(). NuttX does not currently support effective user/group IDs, but these stubs will support linkage of appliations that expect these POSIX standard interfaces. 2019-09-03 10:57:51 -06:00
lib_geteuid.c libc/libc/unistd/: Add stubs for geteuid(), getegid(), seteuid(), and setegid(). NuttX does not currently support effective user/group IDs, but these stubs will support linkage of appliations that expect these POSIX standard interfaces. 2019-09-03 10:57:51 -06:00
lib_getgid.c libc/libc/unistd/: Add stubs for geteuid(), getegid(), seteuid(), and setegid(). NuttX does not currently support effective user/group IDs, but these stubs will support linkage of appliations that expect these POSIX standard interfaces. 2019-09-03 10:57:51 -06:00
lib_gethostname.c libc: Make gethostname as syscall instead of uname 2020-07-30 10:33:08 +09:00
lib_getopt.c syscall: Fix typo error in cvs and header file 2020-05-07 10:31:05 -06:00
lib_getoptargp.c This commit moves all of the libraries under a common directory called libs/. This most certainly break libcxx and uClibc++ for now. 2018-05-29 13:21:26 -06:00
lib_getoptindp.c This commit moves all of the libraries under a common directory called libs/. This most certainly break libcxx and uClibc++ for now. 2018-05-29 13:21:26 -06:00
lib_getoptoptp.c This commit moves all of the libraries under a common directory called libs/. This most certainly break libcxx and uClibc++ for now. 2018-05-29 13:21:26 -06:00
lib_getpriority.c unistd/priority: Implement [s/g]etpriority(2) syscall 2020-09-19 01:06:51 -07:00
lib_getrlimit.c libs/libc/unistd: add dummy getrlimit & setrlimit support 2020-09-15 10:28:21 -03:00
lib_getrusage.c Change all files come from Xiaomi/Pinecone to Apache License 2.0 2020-08-22 17:37:21 -06:00
lib_gettid.c Move gettid() implementation to /libs/libc/unistd 2020-09-22 19:40:56 -07:00
lib_getuid.c sched/group and syscall/: Implement 'real' setuid, getuid, setgid, and getgid interfaces. These will be inheritance by all child task groups. 2019-08-06 14:13:43 -06:00
lib_pathconf.c libc: Implement pathconf and fpathconf 2020-06-23 17:34:54 +01:00
lib_pipe2.c libs/libc/unistd: Implement pipe2(2) syscall 2020-09-18 20:01:26 -07:00
lib_pipe.c libs/libc/unistd: Implement pipe2(2) syscall 2020-09-18 20:01:26 -07:00
lib_restoredir.c libc: Implement ftw and nftw function 2020-08-11 16:44:42 +09:00
lib_setegid.c libc/libc/unistd/: Add stubs for geteuid(), getegid(), seteuid(), and setegid(). NuttX does not currently support effective user/group IDs, but these stubs will support linkage of appliations that expect these POSIX standard interfaces. 2019-09-03 10:57:51 -06:00
lib_seteuid.c libc/libc/unistd/: Add stubs for geteuid(), getegid(), seteuid(), and setegid(). NuttX does not currently support effective user/group IDs, but these stubs will support linkage of appliations that expect these POSIX standard interfaces. 2019-09-03 10:57:51 -06:00
lib_setgid.c sched/group/group_setuid.c and group_setguid.c: Verify that the UID/GID is within range. 2019-08-10 10:42:53 -06:00
lib_sethostname.c Fix nxstyle issue 2020-05-01 10:43:47 -03:00
lib_setpriority.c unistd/priority: Implement [s/g]etpriority(2) syscall 2020-09-19 01:06:51 -07:00
lib_setregid.c Remove exra whitespace from files (#189) 2020-01-31 09:24:49 -06:00
lib_setreuid.c Remove exra whitespace from files (#189) 2020-01-31 09:24:49 -06:00
lib_setrlimit.c libs/libc/unistd: add dummy getrlimit & setrlimit support 2020-09-15 10:28:21 -03:00
lib_setuid.c libs/libc/unistd: Stubs for setuid and setgid. Added stubbed implementations of setuid and setgid. These functions are essentially stubs pretending that NuttX supported users and groups and that the only configured user and group in the system were both 'root' with a uid and a gid of 0, respectively. The intent is not to provide meaningful new features, but to ease porting of foreign source code to NuttX. 2019-08-06 07:17:23 -06:00
lib_sleep.c This commit moves all of the libraries under a common directory called libs/. This most certainly break libcxx and uClibc++ for now. 2018-05-29 13:21:26 -06:00
lib_statvfs.c fs/vfs: Implement statvfs and fstatvfs 2020-07-13 20:25:03 +01:00
lib_swab.c This commit moves all of the libraries under a common directory called libs/. This most certainly break libcxx and uClibc++ for now. 2018-05-29 13:21:26 -06:00
lib_sysconf.c libc: sysconf support _SC_NPROCESSORS_CONF/_SC_NPROCESSORS_ONLN 2020-06-27 22:43:13 +01:00
lib_truncate.c This commit moves all of the libraries under a common directory called libs/. This most certainly break libcxx and uClibc++ for now. 2018-05-29 13:21:26 -06:00
lib_usleep.c This commit moves all of the libraries under a common directory called libs/. This most certainly break libcxx and uClibc++ for now. 2018-05-29 13:21:26 -06:00
lib_utimes.c libs/libc/time: Add stub for utimes 2020-08-29 23:21:47 +08:00
Make.defs Move gettid() implementation to /libs/libc/unistd 2020-09-22 19:40:56 -07:00