summaryrefslogtreecommitdiff
path: root/process.c
diff options
context:
space:
mode:
Diffstat (limited to 'process.c')
-rw-r--r--process.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/process.c b/process.c
index 1f9d578..68e7bc1 100644
--- a/process.c
+++ b/process.c
@@ -58,8 +58,8 @@ static const char *state_string (struct proc_stat *ps)
static long long int timeval_jiffies (time_value_t tv)
{
- double secs = tv.seconds + tv.microseconds / 1000000.;
- return secs * opt_clk_tck;
+ double secs = tv.seconds * 1000000. + tv.microseconds;
+ return secs * opt_clk_tck / 1000000.;
}
/* Actual content generators */