diff options
| author | [email protected] <[email protected]> | 2011-08-28 15:57:10 +0000 |
|---|---|---|
| committer | [email protected] <[email protected]> | 2011-08-28 15:57:10 +0000 |
| commit | 472cc9334ac63bdd041f83e884757c75a30651c7 (patch) | |
| tree | 476ced7ae5eb53a7ae3be460ea9baea8cd6037d6 /include/rtthread.h | |
| parent | da74af2347cfee577b202cf4e26c1af16c05f5b6 (diff) | |
add errno implementation in RT-Thread.
git-svn-id: https://rt-thread.googlecode.com/svn/trunk@1682 bbd45198-f89e-11dd-88c7-29a3b14d5316
Diffstat (limited to 'include/rtthread.h')
| -rw-r--r-- | include/rtthread.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/include/rtthread.h b/include/rtthread.h index 417c86afee..08923f7a32 100644 --- a/include/rtthread.h +++ b/include/rtthread.h @@ -365,6 +365,12 @@ void rt_kprintf(const char *fmt, ...); rt_err_t rt_get_errno(void); void rt_set_errno(rt_err_t no); +int *_rt_errno(void); +#ifndef RT_USING_NEWLIB +#ifndef errno +#define errno *_rt_errno() +#endif +#endif void* rt_memset(void *src, int c, rt_ubase_t n); void* rt_memcpy(void *dest, const void *src, rt_ubase_t n); |
