summaryrefslogtreecommitdiff
path: root/lib/getloadavg.c
diff options
context:
space:
mode:
authorPaul Eggert <eggert@cs.ucla.edu>2005-07-03 07:14:28 +0000
committerPaul Eggert <eggert@cs.ucla.edu>2005-07-03 07:14:28 +0000
commitbd1806f708eeb6da8682e1612f5e21fa3a664be5 (patch)
tree543991b0fa6d8a90a0094fe9c4161151703aebd1 /lib/getloadavg.c
parentf21950385bab4eef15a0c548b880c999bf899166 (diff)
downloadcoreutils-bd1806f708eeb6da8682e1612f5e21fa3a664be5.tar.xz
Include fcntl--.h rather than fcntl.h.
Do not include unistd-safer.h. (getloadavg): Don't call fd_safer; no longer needed now that we include fcntl--.h.
Diffstat (limited to 'lib/getloadavg.c')
-rw-r--r--lib/getloadavg.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/lib/getloadavg.c b/lib/getloadavg.c
index 9a4988e8b..bf57e1040 100644
--- a/lib/getloadavg.c
+++ b/lib/getloadavg.c
@@ -445,9 +445,7 @@
# include <sys/dg_sys_info.h>
# endif
-# include <fcntl.h>
-
-# include "unistd-safer.h"
+# include "fcntl--.h"
/* Avoid static vars inside a function since in HPUX they dump as pure. */
@@ -907,7 +905,7 @@ getloadavg (double loadavg[], int nelem)
if (!getloadavg_initialized)
{
# ifndef SUNOS_5
- channel = fd_safer (open ("/dev/kmem", O_RDONLY));
+ channel = open ("/dev/kmem", O_RDONLY);
if (channel >= 0)
{
/* Set the channel to close on exec, so it does not