summaryrefslogtreecommitdiff
path: root/src/OS/os.c-Linux-libc5
diff options
context:
space:
mode:
authorPhilip Hazel <ph10@hermes.cam.ac.uk>2005-06-27 10:40:14 +0000
committerPhilip Hazel <ph10@hermes.cam.ac.uk>2005-06-27 10:40:14 +0000
commite7ad8a65f1285fad97e1f283cde98eadf1d025f2 (patch)
treef6cf3c0f6b6f79a650d9c29fded1bf73a69ee4bf /src/OS/os.c-Linux-libc5
parent7cb24976e7964b7e03c9ea95e65a86f287d45bcc (diff)
Removed support for Linux-libc5. It must be well obsolete, and the code
in the os-type script was giving problems when libc.so lives in lib64, like on x86_64 Fedora Core.
Diffstat (limited to 'src/OS/os.c-Linux-libc5')
-rw-r--r--src/OS/os.c-Linux-libc539
1 files changed, 0 insertions, 39 deletions
diff --git a/src/OS/os.c-Linux-libc5 b/src/OS/os.c-Linux-libc5
deleted file mode 100644
index cbda9e6fa..000000000
--- a/src/OS/os.c-Linux-libc5
+++ /dev/null
@@ -1,39 +0,0 @@
-/* $Cambridge: exim/src/OS/os.c-Linux-libc5,v 1.1 2004/10/06 15:07:39 ph10 Exp $ */
-
-/*************************************************
-* Exim - an Internet mail transport agent *
-*************************************************/
-
-/* Copyright (c) University of Cambridge 2001 */
-/* See the file NOTICE for conditions of use and distribution. */
-
-/* Linux-specific code. This is concatenated onto the generic src/os.c file.
-Linux has an apparently unique way of getting the load average, so we provide a
-unique function here, and define OS_LOAD_AVERAGE to stop src/os.c trying to
-provide the function. The macro may be set initially anyway, when compiling os.
-for utilities that don't want this function. */
-
-#ifndef OS_LOAD_AVERAGE
-#define OS_LOAD_AVERAGE
-
-int
-os_getloadavg(void)
-{
-char buffer[40];
-double avg;
-int count;
-int fd = open ("/proc/loadavg", O_RDONLY);
-if (fd == -1) return -1;
-count = read (fd, buffer, sizeof(buffer));
-(void)close (fd);
-if (count <= 0) return -1;
-count = sscanf (buffer, "%lf", &avg);
-if (count < 1) return -1;
-
-return (int)(avg * 1000.0);
-}
-
-#endif /* OS_LOAD_AVERAGE */
-
-/* End of os.c-Linux */
-