aboutsummaryrefslogtreecommitdiff
path: root/procps/uptime.c
diff options
context:
space:
mode:
authorEric Andersen <andersen@codepoet.org>2000-06-26 10:45:52 +0000
committerEric Andersen <andersen@codepoet.org>2000-06-26 10:45:52 +0000
commit10dc9d4d17e6880bfdfd253716ce72ec1243227f (patch)
treef3c2aa6ab3dadf1b4bf710c7957e72faddebd75f /procps/uptime.c
parent8a24a6783af7a0d54b1f2ebcda5b07757bd19c99 (diff)
downloadbusybox-10dc9d4d17e6880bfdfd253716ce72ec1243227f.tar.gz
Updates to handle Linux 2.4.0 kernels (kludged around the "none" entries in
/proc/mounts, added a hack to make sysinfo work with both old and new kernels). -Erik
Diffstat (limited to 'procps/uptime.c')
-rw-r--r--procps/uptime.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/procps/uptime.c b/procps/uptime.c
index 67ca34d75..efdbccf00 100644
--- a/procps/uptime.c
+++ b/procps/uptime.c
@@ -31,13 +31,14 @@
#include "internal.h"
#include <stdio.h>
#include <time.h>
-#include <sys/sysinfo.h>
+#include <errno.h>
#define FSHIFT 16 /* nr of bits of precision */
#define FIXED_1 (1<<FSHIFT) /* 1.0 as fixed-point */
#define LOAD_INT(x) ((x) >> FSHIFT)
#define LOAD_FRAC(x) LOAD_INT(((x) & (FIXED_1-1)) * 100)
+
extern int uptime_main(int argc, char **argv)
{
int updays, uphours, upminutes;