1
0
mirror of https://github.com/Llewellynvdm/conky.git synced 2024-11-15 09:44:04 +00:00

Fix execi when interval is larger than system uptime (sf.net #3432429)

bug reported by Deciare
This commit is contained in:
Pavel Labath 2011-11-05 17:21:23 +01:00
parent 505a4bb6b1
commit 742dbbffaa

View File

@ -37,6 +37,7 @@
#include <stdio.h>
#include <sys/types.h>
#include <sys/wait.h>
#include <math.h>
#include <unistd.h>
struct execi_data {
@ -229,6 +230,7 @@ void scan_execi_arg(struct text_object *obj, const char *arg)
ed = malloc(sizeof(struct execi_data));
memset(ed, 0, sizeof(struct execi_data));
ed->last_update = -INFINITY;
if (sscanf(arg, "%f %n", &ed->interval, &n) <= 0) {
NORM_ERR("${execi* <interval> command}");