diff options
| author | guo <[email protected]> | 2021-10-14 12:00:15 +0800 |
|---|---|---|
| committer | GitHub <[email protected]> | 2021-10-14 12:00:15 +0800 |
| commit | 78db48ba78a1cc3f85f26b31f084887cd9698ee3 (patch) | |
| tree | 72d517895678e6c7d98204d2164d288d48b5841f /components/libc/compilers/dlib/libc.c | |
| parent | 9aeb8e7fb4a175c9d2034fce4ce013588f6223d2 (diff) | |
| parent | a354f846e8699fbb8152cfa721f5b9a1e3a2c1a4 (diff) | |
Merge pull request #5169 from mysterywolf/libc
[libc]&[dfs] remove unnecessary RT_USING_POSIX and RT_USING_DFS_DEVFS
Diffstat (limited to 'components/libc/compilers/dlib/libc.c')
| -rw-r--r-- | components/libc/compilers/dlib/libc.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/components/libc/compilers/dlib/libc.c b/components/libc/compilers/dlib/libc.c index f540ac955f..ac3d78f1f9 100644 --- a/components/libc/compilers/dlib/libc.c +++ b/components/libc/compilers/dlib/libc.c @@ -17,23 +17,23 @@ int libc_system_init(void) { -#if defined(RT_USING_DFS) && defined(RT_USING_DFS_DEVFS) +#ifdef RT_USING_DFS_DEVFS rt_device_t dev_console; dev_console = rt_console_get_device(); if (dev_console) { - #if defined(RT_USING_POSIX) + #ifdef RT_USING_POSIX libc_stdio_set_console(dev_console->parent.name, O_RDWR); #else libc_stdio_set_console(dev_console->parent.name, O_WRONLY); - #endif + #endif /* RT_USING_POSIX */ } -#endif +#endif /* RT_USING_DFS_DEVFS */ #if defined (RT_USING_PTHREADS) && !defined (RT_USING_COMPONENTS_INIT) pthread_system_init(); -#endif +#endif /* defined (RT_USING_PTHREADS) && !defined (RT_USING_COMPONENTS_INIT) */ return 0; } |
