diff options
-rw-r--r-- | src/charts.c | 6 | ||||
-rw-r--r-- | src/charts.h | 2 |
2 files changed, 4 insertions, 4 deletions
diff --git a/src/charts.c b/src/charts.c index 57e3dc9..07c9e8d 100644 --- a/src/charts.c +++ b/src/charts.c @@ -1255,8 +1255,8 @@ static float delta(struct timeval *cur, struct timeval *prev) } -/* update the charts if necessary, return if updating occurred, and duration before another update needed in *desired_delay */ -int vwm_charts_update(vwm_charts_t *charts, int *desired_delay) +/* update the charts if necessary, return if updating occurred, and duration before another update needed in *desired_delay_us */ +int vwm_charts_update(vwm_charts_t *charts, int *desired_delay_us) { float this_delta = 0.0f; int ret = 0; @@ -1311,7 +1311,7 @@ int vwm_charts_update(vwm_charts_t *charts, int *desired_delay) } /* TODO: make some effort to compute how long to sleep, but this is perfectly fine for now. */ - *desired_delay = charts->sampling_interval == INFINITY ? -1 : charts->sampling_interval * 300.0; + *desired_delay_us = charts->sampling_interval == INFINITY ? -1 : charts->sampling_interval * 300.0; return ret; } diff --git a/src/charts.h b/src/charts.h index c6bf88f..e175d18 100644 --- a/src/charts.h +++ b/src/charts.h @@ -18,7 +18,7 @@ void vwm_charts_destroy(vwm_charts_t *charts); void vwm_charts_rate_increase(vwm_charts_t *charts); void vwm_charts_rate_decrease(vwm_charts_t *charts); void vwm_charts_rate_set(vwm_charts_t *charts, unsigned hertz); -int vwm_charts_update(vwm_charts_t *charts, int *desired_delay); +int vwm_charts_update(vwm_charts_t *charts, int *desired_delay_us); vwm_chart_t * vwm_chart_create(vwm_charts_t *charts, int pid, int width, int height, const char *name); void vwm_chart_destroy(vwm_charts_t *charts, vwm_chart_t *chart); |