aboutsummaryrefslogtreecommitdiff
path: root/usr.bin/w
diff options
context:
space:
mode:
authorEd Maste <emaste@FreeBSD.org>2012-10-12 15:03:28 +0000
committerEd Maste <emaste@FreeBSD.org>2012-10-12 15:03:28 +0000
commitb6eec535d31e742fce682182cd67c651ec1b9e80 (patch)
tree9384b63f96b450fde2b80bbe37a3e8c4af547491 /usr.bin/w
parentcfccce310aa798e9ddd339556d658676c5b79a7f (diff)
downloadsrc-b6eec535d31e742fce682182cd67c651ec1b9e80.tar.gz
src-b6eec535d31e742fce682182cd67c651ec1b9e80.zip
Use CLOCK_UPTIME to get the uptime.
Notes
Notes: svn path=/head/; revision=241484
Diffstat (limited to 'usr.bin/w')
-rw-r--r--usr.bin/w/w.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/usr.bin/w/w.c b/usr.bin/w/w.c
index 8441ce5ee9a8..2e19bb11fa6c 100644
--- a/usr.bin/w/w.c
+++ b/usr.bin/w/w.c
@@ -447,7 +447,7 @@ pr_header(time_t *nowp, int nusers)
/*
* Print how long system has been up.
*/
- if (clock_gettime(CLOCK_MONOTONIC, &tp) != -1) {
+ if (clock_gettime(CLOCK_UPTIME, &tp) != -1) {
uptime = tp.tv_sec;
if (uptime > 60)
uptime += 30;