Merge pull request #4936 from greedyhao/newlib-fix

[newlib] fix compile error when closing RT_USING_CONSOLE
This commit is contained in:
Bernard Xiong 2021-08-11 23:20:56 +08:00 committed by GitHub
commit da4617f2c8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -210,7 +210,7 @@ int _wait_r(struct _reent *ptr, int *status)
_ssize_t _write_r(struct _reent *ptr, int fd, const void *buf, size_t nbytes)
{
#ifndef RT_USING_DFS
#ifdef RT_USING_DEVICE
#if defined(RT_USING_CONSOLE) && defined(RT_USING_DEVICE)
if (fileno(stdout) == fd)
{
rt_device_t console;