]> git.ipfire.org Git - thirdparty/coreutils.git/commitdiff
Assume HAVE_UNISTD_H, i.e., include <unistd.h> unconditionally.
authorJim Meyering <jim@meyering.net>
Sat, 2 Jul 2005 08:41:46 +0000 (08:41 +0000)
committerJim Meyering <jim@meyering.net>
Sat, 2 Jul 2005 08:41:46 +0000 (08:41 +0000)
41 files changed:
lib/ChangeLog
lib/backupfile.c
lib/canon-host.c
lib/canonicalize.c
lib/chown.c
lib/cloexec.c
lib/dup-safer.c
lib/dup2.c
lib/euidaccess.c
lib/fd-safer.c
lib/fileblocks.c
lib/fopen-safer.c
lib/fsusage.c
lib/ftruncate.c
lib/getcwd.c
lib/getcwd.h
lib/getloadavg.c
lib/getpagesize.h
lib/getugroups.c
lib/group-member.c
lib/human.h
lib/idcache.c
lib/mkdir-p.c
lib/mountlist.c
lib/nanosleep.c
lib/pathmax.h
lib/physmem.c
lib/posixver.c
lib/putenv.c
lib/raise.c
lib/safe-read.c
lib/same.c
lib/save-cwd.c
lib/setenv.c
lib/settime.c
lib/tempname.c
lib/unlinkdir.c
lib/unsetenv.c
lib/userspec.c
lib/xgethostname.c
lib/xreadlink.c

index 52708dab86fbd4e78c4a70f2a9951f90198f5dd6..abf855d1d9fc2b65bee92a0905b0cf3159da4989 100644 (file)
@@ -1,3 +1,15 @@
+2005-07-02  Jim Meyering  <jim@meyering.net>
+
+       * backupfile.c, canon-host.c, canonicalize.c, chown.c, cloexec.c:
+       * dup-safer.c, dup2.c, euidaccess.c, fd-safer.c, fileblocks.c:
+       * fopen-safer.c, fsusage.c, ftruncate.c, getcwd.c, getcwd.h:
+       * getloadavg.c, getopt_.h, getpagesize.h, getugroups.c, group-member.c:
+       * human.h, idcache.c, mkdir-p.c, mountlist.c, nanosleep.c, pathmax.h:
+       * physmem.c, posixver.c, putenv.c, raise.c, safe-read.c, same.c:
+       * save-cwd.c, setenv.c, settime.c, tempname.c, unlinkdir.c:
+       * unsetenv.c, userspec.c, xgethostname.c, xreadlink.c:
+       Assume HAVE_UNISTD_H, i.e., include <unistd.h> unconditionally.
+
 2005-07-01  Jim Meyering  <jim@meyering.net>
 
        * chown.c, cloexec.c, dup-safer.c, dup2.c, fsusage.c, getcwd.c:
index f48a1cde87ea22e440dadc43908ca4917c3a7c12..ebc0fce87a9450abbc6df17d39515ad2c21eb3d0 100644 (file)
@@ -38,9 +38,7 @@
 
 #include <limits.h>
 
-#if HAVE_UNISTD_H
-# include <unistd.h>
-#endif
+#include <unistd.h>
 
 #if HAVE_DIRENT_H
 # include <dirent.h>
index 0d469ba1a48164bb700f28d23a1c8d32eb3bfa94..63c437e1ebe8269963e4f9ff5eb34d447558a3a8 100644 (file)
@@ -24,9 +24,7 @@
 #endif
 
 #include <sys/types.h>
-#ifdef HAVE_UNISTD_H
-# include <unistd.h>
-#endif
+#include <unistd.h>
 #include <stdlib.h>
 #include <string.h>
 #ifdef HAVE_NETDB_H
index 571fa19e231dda063a9729d03aaf4652bb0043c7..b4d4c445b946f9e9921296b2905f621e3a223602 100644 (file)
@@ -40,9 +40,7 @@ void free ();
 
 #include <sys/stat.h>
 
-#if HAVE_UNISTD_H
-# include <unistd.h>
-#endif
+#include <unistd.h>
 
 #include <errno.h>
 #include <stddef.h>
index 2d97902e631a5ca42c0a11681b65c1ee5a5ad3a6..d6c64a48b3f0de57302844724544a115727ddab4 100644 (file)
@@ -27,9 +27,7 @@
 
 #include <sys/types.h>
 #include <sys/stat.h>
-#if HAVE_UNISTD_H
-# include <unistd.h>
-#endif
+#include <unistd.h>
 #include <fcntl.h>
 #include <errno.h>
 
index 79d4ed0b8d29a0e03bcba408cf45f26b39e94b36..cfffa53b83ebc4aaa00ddbea032b16168cd48fe7 100644 (file)
@@ -23,9 +23,7 @@
 
 #include "cloexec.h"
 
-#if HAVE_UNISTD_H
-# include <unistd.h>
-#endif
+#include <unistd.h>
 
 #include <fcntl.h>
 
index 034297aa1ef415be1e22d1933ca5bcf992824c13..1c46b6e7228a0a0a612ef2bfb04ecb4b4b13d6ff 100644 (file)
@@ -25,9 +25,7 @@
 
 #include <fcntl.h>
 
-#if HAVE_UNISTD_H
-# include <unistd.h>
-#endif
+#include <unistd.h>
 #ifndef STDERR_FILENO
 # define STDERR_FILENO 2
 #endif
index 77deaf62d0b4751673d8c7f033020d53c9f23c7c..315c82b152710281e1ab2a21ee864e2012a95321 100644 (file)
@@ -25,9 +25,7 @@
 
 #include <fcntl.h>
 
-#if HAVE_UNISTD_H
-# include <unistd.h>
-#endif
+#include <unistd.h>
 
 #ifndef F_DUPFD
 static int
index 4bb93aa0b069314d43fb639f449c8063f5d736ca..4e1260b25b40dfe2735b14e33cd18b595db34dd8 100644 (file)
 
 #include <sys/types.h>
 #include <sys/stat.h>
-
-#if HAVE_UNISTD_H || defined _LIBC
-# include <unistd.h>
-#endif
+#include <unistd.h>
 
 #if HAVE_LIBGEN_H
 # include <libgen.h>
index 93768600f742a3377782bca49db45723fb8ecd79..6b50451338a4181df094cf879662db2a8d2dba87 100644 (file)
@@ -26,9 +26,7 @@
 
 #include <errno.h>
 
-#if HAVE_UNISTD_H
-# include <unistd.h>
-#endif
+#include <unistd.h>
 #ifndef STDIN_FILENO
 # define STDIN_FILENO 0
 #endif
index dd6fb6d3a7769360e5878cf8edc95b36cf15db2e..9367176e346e8628af3d1349aec4345869c13010 100644 (file)
@@ -30,9 +30,7 @@
 
 #if !HAVE_STRUCT_STAT_ST_BLOCKS && !defined _POSIX_SOURCE && defined BSIZE
 
-# if HAVE_UNISTD_H
-#  include <unistd.h>
-# endif
+# include <unistd.h>
 
 # ifndef NINDIR
 
index 1eb594b32f248e12e2cab8083b029aa8be5e0036..4b74b8f3bf6e4c4730c2c333c99480dee2389fec 100644 (file)
@@ -21,9 +21,7 @@
 # include <config.h>
 #endif
 
-#if HAVE_UNISTD_H
-# include <unistd.h>
-#endif
+#include <unistd.h>
 #include <unistd-safer.h>
 
 #ifndef STDERR_FILENO
index 83d26af88bd724aeddd6efd40794b4a37c0db694..81c28690f339dd2cd195a06ef9f9078e95748b3e 100644 (file)
@@ -27,9 +27,7 @@
 #if HAVE_STDINT_H
 # include <stdint.h>
 #endif
-#if HAVE_UNISTD_H
-# include <unistd.h>
-#endif
+#include <unistd.h>
 #ifndef UINTMAX_MAX
 # define UINTMAX_MAX ((uintmax_t) -1)
 #endif
index c062fe80d81f533d04d6589dfb9c864161db2779..669d59490379d9a67801b302c9c68e6ed7b070f2 100644 (file)
@@ -23,9 +23,7 @@ ftruncate (int fd, off_t length)
 
 #  include <sys/stat.h>
 #  include <errno.h>
-#  if HAVE_UNISTD_H
-#   include <unistd.h>
-#  endif
+#  include <unistd.h>
 
 int
 ftruncate (int fd, off_t length)
index 86070ead87730d140653ac7a6371cb3f26c57d17..be10e4f1b8032e9d0772e86c0c1e166ab73b77cf 100644 (file)
 # define _D_ALLOC_NAMLEN(d) (_D_EXACT_NAMLEN (d) + 1)
 #endif
 
-#if HAVE_UNISTD_H || _LIBC
-# include <unistd.h>
-#endif
-
+#include <unistd.h>
 #include <stdlib.h>
 #include <string.h>
 
index d69fe206b8b25442b339bed292e543642697b1b3..0503ff8247d9eab8ff59c0ce43a6e5c791d1c22a 100644 (file)
@@ -22,9 +22,7 @@
    cause confusion if included after this file.  */
 
 #include <stdlib.h>
-#if HAVE_UNISTD_H
-# include <unistd.h>
-#endif
+#include <unistd.h>
 
 /* If necessary, systematically rename identifiers so that they do not
    collide with the system function.  Renaming avoids problems with
index d1ed95af48bc4c42df2fe35b79affe2dc036871b..9a4988e8b0775667efbabd7b8ba522a54b4425ee 100644 (file)
 #  define LDAV_SYMBOL "avenrun"
 # endif
 
-# ifdef HAVE_UNISTD_H
-#  include <unistd.h>
-# endif
+# include <unistd.h>
 
 /* LOAD_AVE_TYPE should only get defined if we're going to use the
    nlist method.  */
index 17f070f634386da1beb124e3be1a9664f84a35f8..5cce3c908083500ba9d2178528bcdab3cb79bbb5 100644 (file)
@@ -1,5 +1,5 @@
 /* Emulate getpagesize on systems that lack it.
-   Copyright (C) 1999, 2000, 2004 Free Software Foundation, Inc.
+   Copyright (C) 1999, 2000, 2004, 2005 Free Software Foundation, Inc.
 
    This program is free software; you can redistribute it and/or modify
    it under the terms of the GNU General Public License as published by
@@ -18,9 +18,7 @@
 
 #ifndef HAVE_GETPAGESIZE
 
-#ifdef HAVE_UNISTD_H
-# include <unistd.h>
-#endif
+#include <unistd.h>
 
 #if !defined getpagesize && defined _SC_PAGESIZE
 # if !(defined VMS && __VMS_VER < 70000000)
index 599bf1cead63cb5d13586383c4454ebba73582e7..60b04682a687846550d54c6f713f413cac39ee16 100644 (file)
@@ -27,9 +27,7 @@
 #include <stdio.h> /* grp.h on alpha OSF1 V2.0 uses "FILE *". */
 #include <grp.h>
 
-#ifdef HAVE_UNISTD_H
-# include <unistd.h>
-#endif
+#include <unistd.h>
 
 #include <errno.h>
 #ifndef EOVERFLOW
index 67fb9fd7c1837152876989b17f0cea959924147f..a338674b2c9ceea55e25363572368cf2f29f9a8c 100644 (file)
@@ -26,9 +26,7 @@
 #include <sys/types.h>
 #include <stdlib.h>
 
-#if HAVE_UNISTD_H
-# include <unistd.h>
-#endif
+#include <unistd.h>
 
 #include "xalloc.h"
 
index 3b23c123b8411e911815b92d4bd69478ac8daae3..15ca36bf839de488560693644e9443bf92288b53 100644 (file)
@@ -32,9 +32,7 @@
 # if HAVE_STDINT_H
 #  include <stdint.h>
 # endif
-# if HAVE_UNISTD_H
-#  include <unistd.h>
-# endif
+# include <unistd.h>
 
 /* A conservative bound on the maximum length of a human-readable string.
    The output can be the square of the largest uintmax_t, so double
index 82dec8d90c1e2477c6f69de6e15ddc0fffb6fe8f..0673d80fc1f05267e963babbc2635bf00dd91c0a 100644 (file)
@@ -27,9 +27,7 @@
 #include <pwd.h>
 #include <grp.h>
 
-#if HAVE_UNISTD_H
-# include <unistd.h>
-#endif
+#include <unistd.h>
 
 #include "xalloc.h"
 
index 962f452bd3ff18ef7ed921e32c0f8ce536443053..315a3a06a97748cba8baf4a8931a3c2467eb0ed6 100644 (file)
@@ -30,9 +30,7 @@
 #include <stdio.h>
 #include <sys/types.h>
 #include <sys/stat.h>
-#if HAVE_UNISTD_H
-# include <unistd.h>
-#endif
+#include <unistd.h>
 
 #include <stdlib.h>
 #include <errno.h>
index a8ef87d8c8abdc94f2ceec66c9141b92a8bc46a0..da39daaef8c467696be1b5ed237a952b06ed9604 100644 (file)
@@ -37,9 +37,7 @@ char *strstr ();
 
 #include <fcntl.h>
 
-#ifdef HAVE_UNISTD_H
-# include <unistd.h>
-#endif
+#include <unistd.h>
 
 #if HAVE_SYS_PARAM_H
 # include <sys/param.h>
index f41aed2cf3ad69a7809ac325e1e89142967acc4c..97d60d864f85ad85bbae55c7b2f3c6a371746415 100644 (file)
@@ -30,9 +30,7 @@
 
 #include <errno.h>
 
-#if HAVE_UNISTD_H
-# include <unistd.h>
-#endif
+#include <unistd.h>
 
 #include "timespec.h"
 
index 613c56c0974ccead42c1797b94a3a43df2dcf0bb..6941e457e39c6c18da9038f77d3f680d3ae6c9fd 100644 (file)
@@ -18,9 +18,7 @@
 #ifndef _PATHMAX_H
 # define _PATHMAX_H
 
-# if HAVE_UNISTD_H
-#  include <unistd.h>
-# endif
+# include <unistd.h>
 
 # include <limits.h>
 
index dabb00ccbea7b78bab217e70b40cc52d797ea9d4..99fc8465b899aac3f0b1efcbc41b14d90b1d52ab 100644 (file)
@@ -23,9 +23,7 @@
 
 #include "physmem.h"
 
-#if HAVE_UNISTD_H
-# include <unistd.h>
-#endif
+#include <unistd.h>
 
 #if HAVE_SYS_PSTAT_H
 # include <sys/pstat.h>
index 2fa097ae6c41e0d7b2678d9ef23189d0038a830b..7fd7cd3b888218f3ac8d6ca362ad98acf7b04ff7 100644 (file)
@@ -27,9 +27,7 @@
 #include <limits.h>
 #include <stdlib.h>
 
-#if HAVE_UNISTD_H
-# include <unistd.h>
-#endif
+#include <unistd.h>
 #ifndef _POSIX2_VERSION
 # define _POSIX2_VERSION 0
 #endif
index 69fb90be616c2de1ce2b86b8931c559f81288974..0a23694fac249b605f0060ae71e8101c58bef62f 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (C) 1991, 1994, 1997, 1998, 2000, 2003, 2004 Free Software Foundation, Inc.
+/* Copyright (C) 1991, 1994, 1997, 1998, 2000, 2003, 2004, 2005 Free Software Foundation, Inc.
 
    NOTE: The canonical source of this file is maintained with the GNU C
    Library.  Bugs can be reported to bug-glibc@prep.ai.mit.edu.
@@ -39,9 +39,7 @@ void free ();
 
 #include <string.h>
 
-#if defined (__GNU_LIBRARY__) || defined (HAVE_UNISTD_H)
-# include <unistd.h>
-#endif
+#include <unistd.h>
 
 #if HAVE_GNU_LD
 # define environ __environ
index 8eeea5c89051679577a97a15bddcc38a581562b9..1225f764e47e035526d8278785c9d12c3dddbe73 100644 (file)
@@ -21,9 +21,7 @@
 
 #include <sys/types.h>
 #include <signal.h>
-#if HAVE_UNISTD_H
-# include <unistd.h>
-#endif
+#include <unistd.h>
 
 int
 raise (int sig)
index 904fc71f03b69a072b24c19ab4b580129bd70c62..a5108356d981792f0a82ed43fc2629e035846018 100644 (file)
@@ -30,9 +30,7 @@
 
 /* Get ssize_t.  */
 #include <sys/types.h>
-#if HAVE_UNISTD_H
-# include <unistd.h>
-#endif
+#include <unistd.h>
 
 #include <errno.h>
 
index 89ee47dd09c2f496ed8ca41587ce4f6f550ed843..9cbf47a76b18f623d1829298fce1603473fb985e 100644 (file)
@@ -25,9 +25,7 @@
 
 #include <stdbool.h>
 #include <stdio.h>
-#ifdef HAVE_UNISTD_H
-# include <unistd.h>
-#endif
+#include <unistd.h>
 #include <stdlib.h>
 #include <sys/types.h>
 #include <sys/stat.h>
index 5ad790a4d3542a7deafd4f5b9ac6325769e2b1da..aefdb6e7e4f68207a7b0323a8683ba6880a24fcb 100644 (file)
@@ -29,9 +29,7 @@
 #include <stdio.h>
 #include <stdlib.h>
 
-#if HAVE_UNISTD_H
-# include <unistd.h>
-#endif
+#include <unistd.h>
 
 #include <fcntl.h>
 
index 33dbeb7a39f32e21fc6be51ecae169a0796f319d..808820091050afa8d309ef0395e11f3f51c10b44 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (C) 1992,1995-1999,2000-2003 Free Software Foundation, Inc.
+/* Copyright (C) 1992,1995-1999,2000-2003,2005 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
    This program is free software; you can redistribute it and/or modify
@@ -27,9 +27,7 @@
 
 #include <stdlib.h>
 #include <string.h>
-#if _LIBC || HAVE_UNISTD_H
-# include <unistd.h>
-#endif
+#include <unistd.h>
 
 #if !_LIBC
 # include "allocsa.h"
index 459d5436cbdc3b65a93e4c3e30bf00a662e416ca..20edeab28892b4858ae0d744962680b98aee6ef3 100644 (file)
@@ -23,9 +23,7 @@
 
 #include "timespec.h"
 
-#if HAVE_UNISTD_H
-# include <unistd.h>
-#endif
+#include <unistd.h>
 
 #include <errno.h>
 
index 4b0fad3f87f335d12c474b20e630e7fd5898d8d2..27663c23c5eec150abb93d3095592f0b3242229f 100644 (file)
@@ -60,9 +60,7 @@
 # include <inttypes.h>
 #endif
 
-#if HAVE_UNISTD_H || _LIBC
-# include <unistd.h>
-#endif
+#include <unistd.h>
 
 #include <sys/stat.h>
 
index b12d2a4925daf9b08c7e299a9ddbbeba75091069..4d53fa02f9eba59eae803bd963de3040581befe8 100644 (file)
@@ -25,9 +25,7 @@
 #if HAVE_PRIV_H
 # include <priv.h>
 #endif
-#if HAVE_UNISTD_H
-# include <unistd.h>
-#endif
+#include <unistd.h>
 
 #if ! UNLINK_CANNOT_UNLINK_DIR
 
index 4b53fc9c8bda2ec948a2e25c8dce67bdfe7c3b6c..d96389656efd518b9e55c2e8f627abecddcc517a 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (C) 1992,1995-1999,2000-2002 Free Software Foundation, Inc.
+/* Copyright (C) 1992,1995-1999,2000-2002,2005 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
    This program is free software; you can redistribute it and/or modify
@@ -29,9 +29,7 @@ extern int errno;
 
 #include <stdlib.h>
 #include <string.h>
-#if _LIBC || HAVE_UNISTD_H
-# include <unistd.h>
-#endif
+#include <unistd.h>
 
 #if !_LIBC
 # define __environ     environ
index 5f5c5bf43c8650ce389301aa360a10a08f8622e8..d09a6b2126d0e3ec8d63b71b2c801147e2e4a27c 100644 (file)
@@ -39,9 +39,7 @@
 #include <stdlib.h>
 #include <string.h>
 
-#if HAVE_UNISTD_H
-# include <unistd.h>
-#endif
+#include <unistd.h>
 
 #include "intprops.h"
 #include "inttostr.h"
index 5b8b9b2e860d0b3557aeee41423b60feebff027d..2facf9b1dd525dddb595dc2597914e56d8f1214c 100644 (file)
@@ -29,9 +29,7 @@
 #include <stdlib.h>
 #include <errno.h>
 
-#if HAVE_UNISTD_H
-# include <unistd.h>
-#endif
+#include <unistd.h>
 
 #include "xalloc.h"
 
index d56d2a6af40bcc362d602faf9b18c77902473065..63f5ce1bfa9d469e55ee6f993fd1388eff7126ba 100644 (file)
@@ -30,9 +30,7 @@
 #include <limits.h>
 #include <sys/types.h>
 #include <stdlib.h>
-#if HAVE_UNISTD_H
-# include <unistd.h>
-#endif
+#include <unistd.h>
 
 #ifndef SIZE_MAX
 # define SIZE_MAX ((size_t) -1)