diff options
Diffstat (limited to 'src/libc/errno.c')
-rw-r--r-- | src/libc/errno.c | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/src/libc/errno.c b/src/libc/errno.c new file mode 100644 index 00000000..0ba05c99 --- /dev/null +++ b/src/libc/errno.c @@ -0,0 +1,17 @@ +/* + * errno.c + * + * Created on: 1 Oct 2022 + * Author: David + * + * This file replaces the one in newlib in order to avoid pulling the reent struct + */ + +static int globalErrno = 0; + +int * __errno () noexcept +{ + return &globalErrno; +} + +// End |