]> git.ipfire.org Git - thirdparty/coreutils.git/commitdiff
(errno): Remove decl; we now assume C89 or better.
authorPaul Eggert <eggert@cs.ucla.edu>
Mon, 2 Aug 2004 22:41:37 +0000 (22:41 +0000)
committerPaul Eggert <eggert@cs.ucla.edu>
Mon, 2 Aug 2004 22:41:37 +0000 (22:41 +0000)
21 files changed:
lib/canonicalize.c
lib/chown.c
lib/closeout.c
lib/dup-safer.c
lib/dup2.c
lib/exclude.c
lib/fopen-safer.c
lib/ftruncate.c
lib/full-write.c
lib/getcwd.c
lib/lchown.c
lib/memcoll.c
lib/putenv.c
lib/rmdir.c
lib/savedir.c
lib/setenv.c
lib/stat.c
lib/utime.c
lib/xgetcwd.c
lib/xmemcoll.c
lib/xreadlink.c

index 02bea7c5a508dc5c95b39a29fa98fb5cc40f404b..6d1bfbc6f8d207f9a35b3703ccd9b9ec22a8e1b3 100644 (file)
@@ -50,10 +50,6 @@ void free ();
 #include "xalloc.h"
 #include "xgetcwd.h"
 
-#ifndef errno
-extern int errno;
-#endif
-
 #ifndef __set_errno
 # define __set_errno(Val) errno = (Val)
 #endif
@@ -89,7 +85,7 @@ extern int errno;
 char *
 canonicalize_file_name (const char *name)
 {
-#if HAVE_RESOLVEPATH
+# if HAVE_RESOLVEPATH
 
   char *resolved, *extra_buf = NULL;
   size_t resolved_size;
@@ -146,11 +142,11 @@ canonicalize_file_name (const char *name)
 
   return resolved;
 
-#else
+# else
 
   return canonicalize_filename_mode (name, CAN_EXISTING);
 
-#endif /* !HAVE_RESOLVEPATH */
+# endif /* !HAVE_RESOLVEPATH */
 }
 #endif /* !HAVE_CANONICALIZE_FILE_NAME */
 
index 460e4f623a53a6f464cf3ccde5b641c862c58b87..d761c73399ec2a9c7f9787c7a17915d07e4ea870 100644 (file)
@@ -36,9 +36,6 @@
 # include <sys/file.h>
 #endif
 #include <errno.h>
-#ifndef errno
-extern int errno;
-#endif
 
 /* Provide a more-closely POSIX-conforming version of chown on
    systems with one or both of the following problems:
index a551d1ae8be6521e7215efeb87b7996297cd11d9..1b0b50c295a81b27cf87b3ab4ca3b0dce011f64a 100644 (file)
 #include "closeout.h"
 
 #include <stdio.h>
-
 #include <errno.h>
-#ifndef errno
-extern int errno;
-#endif
 
 #include "gettext.h"
 #define _(msgid) gettext (msgid)
index f72fd845f397a1a6e413db765e8b08972220772a..4a820387ebd9895407c3134b28f436e79ce9659c 100644 (file)
@@ -22,9 +22,6 @@
 #endif
 
 #include <errno.h>
-#ifndef errno
-extern int errno;
-#endif
 
 #if HAVE_FCNTL_H
 # include <fcntl.h>
index 32afed50f424728b89e13902f630ad2fbdeff83e..58d4ad2833ad20c3417dd3a0f88822e41990cb3d 100644 (file)
@@ -22,9 +22,6 @@
 #endif
 
 #include <errno.h>
-#ifndef errno
-extern int errno;
-#endif
 
 #if HAVE_FCNTL_H
 # include <fcntl.h>
index 55f1a39185d2d31f72c68b1489882ccb1566f6ba..bfc5a1665ec19713ea27cb9b03e62bee146a38b3 100644 (file)
@@ -28,9 +28,6 @@
 
 #include <ctype.h>
 #include <errno.h>
-#ifndef errno
-extern int errno;
-#endif
 #include <stddef.h>
 #include <stdio.h>
 #include <stdlib.h>
index 6825f9b9f21b4cc5db2d953b73a183c0f7424618..ee41efa13c04b6407b0e537a8d63ef8d2fe0a974 100644 (file)
 #endif
 
 #include <errno.h>
-#ifndef errno
-extern int errno;
-#endif
-
 #include <stdio.h>
 #include <stdio-safer.h>
 
index adf87f64bb112cd851e7e903595f9410f795ba6f..c062fe80d81f533d04d6589dfb9c864161db2779 100644 (file)
@@ -79,9 +79,6 @@ ftruncate (int fd, off_t length)
 #  else /* not F_CHSIZE nor F_FREESP nor HAVE_CHSIZE */
 
 #   include <errno.h>
-#   ifndef errno
-extern int errno;
-#   endif
 
 int
 ftruncate (int fd, off_t length)
index 151370563780d939b77f4f35144575b259a2cfe1..0e15f790c0190bc63b1b90d0132627a8e8fd0f8c 100644 (file)
@@ -28,9 +28,6 @@
 #endif
 
 #include <errno.h>
-#ifndef errno
-extern int errno;
-#endif
 
 #ifdef FULL_READ
 # include "safe-read.h"
index 2968a6e98023d79177028330c388d2b77489da80..e502078ff4d691cf175f3573b5836fd582f871d2 100644 (file)
 
 #include <stdlib.h>
 #include <string.h>
-
 #include <errno.h>
-#ifndef errno
-extern int errno;
-#endif
-
 #include <sys/types.h>
 
 #include "pathmax.h"
index ec754eac89981b2bda0479e0cf837e9e95786cf9..b04fb36468bd5caa343b877e8b5708936a75f206 100644 (file)
@@ -22,9 +22,7 @@
 #include <sys/types.h>
 #include <sys/stat.h>
 #include <errno.h>
-#ifndef errno
-extern int errno;
-#endif
+
 #include "lchown.h"
 #include "stat-macros.h"
 
index 34ae767dbdbb800cc491f5dedace0ed602375fda..72ae17f64c10a6b57d8dbec4a52a624ea91226ea 100644 (file)
 #include "memcoll.h"
 
 #include <errno.h>
-#ifndef errno
-extern int errno;
-#endif
-
 #include <string.h>
 
 /* Compare S1 (with length S1LEN) and S2 (with length S2LEN) according
index 87c5522810ac60ad8b61bf2ad990810642c523ab..2d194046c07f227b185f1ac6a738f79796767b9d 100644 (file)
 /* Include errno.h *after* sys/types.h to work around header problems
    on AIX 3.2.5.  */
 #include <errno.h>
-#if !_LIBC
-# if !defined errno
-extern int errno;
-# endif
+#ifndef __set_errno
 # define __set_errno(ev) ((errno) = (ev))
 #endif
 
index 55fee53c033b8e97f6271bceebd730bcaddc8e84..ddb5c30b2c866036ac0dad3b341d4ccabb5831a5 100644 (file)
 
 #include <sys/types.h>
 #include <sys/stat.h>
-
 #include <errno.h>
-#ifndef errno
-extern int errno;
-#endif
 
 #include "stat-macros.h"
 
index 01499a9ae288143248abed39fd9f8b32914ee2ce..c92e62eadccdf3e6e4f5a62b414efdf1c0e8c300 100644 (file)
@@ -28,9 +28,6 @@
 #include <sys/types.h>
 
 #include <errno.h>
-#ifndef errno
-extern int errno;
-#endif
 
 #if HAVE_DIRENT_H
 # include <dirent.h>
index c3f9dc4ca4495c75803fda6de49581c335310bfd..ae4174af2669509e27ab9408cb1bb3479f88e3cf 100644 (file)
 #include <alloca.h>
 
 #include <errno.h>
-#if !_LIBC
-# if !defined errno && !defined HAVE_ERRNO_DECL
-extern int errno;
-# endif
+#ifndef __set_errno
 # define __set_errno(ev) ((errno) = (ev))
 #endif
 
index 2088db391dd1c8f81c51917709f9f5bd4a8b155c..df0be3a81aa9202a73357a3ecfbac377c0ac8c6e 100644 (file)
@@ -27,9 +27,6 @@
 #include <sys/types.h>
 #include <sys/stat.h>
 #include <errno.h>
-#ifndef errno
-extern int errno;
-#endif
 #if defined LSTAT && ! LSTAT_FOLLOWS_SLASHED_SYMLINK
 # include <stdlib.h>
 # include <string.h>
index 7b87a969df3e2222d8cda34d5fe446711655c94d..3cac548d441fa94522a483291aa64316a6902e58 100644 (file)
@@ -34,9 +34,6 @@
 
 #include <unistd.h>
 #include <errno.h>
-#ifndef errno
-extern int errno;
-#endif
 
 #include "full-write.h"
 #include "safe-read.h"
index 2089b8897c89e98d236c4377638df58ed2894520..5147f51bcb6b8c8170d62d0530bafac76a2269c0 100644 (file)
 
 #include <stdio.h>
 #include <errno.h>
-#ifndef errno
-extern int errno;
-#endif
-
 #include <sys/types.h>
 #include <stdlib.h>
 
index 0e30aef1506718955baf1d423314f76e44abb2e7..89d6fa8e432b3234258cda6295de4d28c6dddc4b 100644 (file)
 #endif
 
 #include <errno.h>
-#ifndef errno
-extern int errno;
-#endif
-
 #include <stdlib.h>
 
 #include "gettext.h"
index 41f5242ea468c947cdb30fcaae3278899823ee9d..2e66c07f240791c8c1b05609da58ca58e6dd3b34 100644 (file)
 
 #include <stdio.h>
 #include <errno.h>
-#ifndef errno
-extern int errno;
-#endif
-
 #include <limits.h>
 #include <sys/types.h>
 #include <stdlib.h>