summaryrefslogtreecommitdiff
path: root/usr.bin/tmux
diff options
context:
space:
mode:
authorNicholas Marriott <nicm@cvs.openbsd.org>2009-11-13 18:13:19 +0000
committerNicholas Marriott <nicm@cvs.openbsd.org>2009-11-13 18:13:19 +0000
commiteaca03fed90a7865a02a28ad29f9eebb8d1eb4b1 (patch)
tree1fc0e509a1176d00b9e073a92c44040cb5e4260e /usr.bin/tmux
parent44ca4ba86dc7ab4722c6f562d09e299e6e6700b8 (diff)
Tidy up and fix some types, prompted by lint via deraadt.
Diffstat (limited to 'usr.bin/tmux')
-rw-r--r--usr.bin/tmux/server-client.c11
1 files changed, 7 insertions, 4 deletions
diff --git a/usr.bin/tmux/server-client.c b/usr.bin/tmux/server-client.c
index bd4b3ed61fc..50cebd4ddf6 100644
--- a/usr.bin/tmux/server-client.c
+++ b/usr.bin/tmux/server-client.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: server-client.c,v 1.19 2009/11/11 08:00:42 nicm Exp $ */
+/* $OpenBSD: server-client.c,v 1.20 2009/11/13 18:13:18 nicm Exp $ */
/*
* Copyright (c) 2009 Nicholas Marriott <nicm@users.sourceforge.net>
@@ -197,7 +197,9 @@ server_client_status_timer(void)
struct session *s;
struct job *job;
struct timeval tv;
- u_int i, interval;
+ u_int i;
+ int interval;
+ time_t difference;
if (gettimeofday(&tv, NULL) != 0)
fatal("gettimeofday failed");
@@ -220,9 +222,10 @@ server_client_status_timer(void)
continue;
interval = options_get_number(&s->options, "status-interval");
- if (tv.tv_sec - c->status_timer.tv_sec >= interval) {
+ difference = tv.tv_sec - c->status_timer.tv_sec;
+ if (difference >= interval) {
RB_FOREACH(job, jobs, &c->status_jobs)
- job_run(job);
+ job_run(job);
c->flags |= CLIENT_STATUS;
}
}