diff options
author | Ralf Corsepius <ralf.corsepius@rtems.org> | 2009-09-30 06:51:15 +0000 |
---|---|---|
committer | Ralf Corsepius <ralf.corsepius@rtems.org> | 2009-09-30 06:51:15 +0000 |
commit | 00da59e4f2375fc3ff0d58b1312d90f3e2fb6b6d (patch) | |
tree | e05cf5ea46c00c2720b2a1a113de9c60e91882e2 /cpukit | |
parent | 2009-09-30 Ralf Corsépius <ralf.corsepius@rtems.org> (diff) | |
download | rtems-00da59e4f2375fc3ff0d58b1312d90f3e2fb6b6d.tar.bz2 |
2009-09-30 Ralf Corsépius <ralf.corsepius@rtems.org>
* libcsupport/src/_rename_r.c: Rework autoconf defines.
Remove unused includes.
Diffstat (limited to 'cpukit')
-rw-r--r-- | cpukit/ChangeLog | 2 | ||||
-rw-r--r-- | cpukit/libcsupport/src/_rename_r.c | 16 |
2 files changed, 8 insertions, 10 deletions
diff --git a/cpukit/ChangeLog b/cpukit/ChangeLog index f193a84458..5cc318632d 100644 --- a/cpukit/ChangeLog +++ b/cpukit/ChangeLog @@ -1,5 +1,7 @@ 2009-09-30 Ralf Corsépius <ralf.corsepius@rtems.org> + * libcsupport/src/_rename_r.c: Rework autoconf defines. + Remove unused includes. * libcsupport/src/__gettod.c: Rework autoconf defines. Eliminate RTEMS_UNIX. * libcsupport/src/_calloc_r.c, libcsupport/src/_realloc_r.c: diff --git a/cpukit/libcsupport/src/_rename_r.c b/cpukit/libcsupport/src/_rename_r.c index d5e493f92e..12eeb59e53 100644 --- a/cpukit/libcsupport/src/_rename_r.c +++ b/cpukit/libcsupport/src/_rename_r.c @@ -15,17 +15,12 @@ #include "config.h" #endif -#include <stdio.h> -#include <reent.h> - -#include <rtems.h> -#include <rtems/libio.h> -#include <errno.h> - -#include <rtems/libio_.h> -#include <rtems/seterr.h> - +#if defined(RTEMS_NEWLIB) && !defined(HAVE__RENAME_R) +#include <sys/types.h> #include <sys/stat.h> +#include <unistd.h> + +#include <reent.h> int _rename_r( struct _reent *ptr __attribute__((unused)), @@ -44,3 +39,4 @@ int _rename_r( return s; return S_ISDIR(sb.st_mode) ? rmdir( old ) : unlink( old ); } +#endif |