1
0
Fork 0
mirror of https://git.rwth-aachen.de/acs/public/villas/node/ synced 2025-03-09 00:00:00 +01:00

stats_collect: fix regression

This commit is contained in:
Steffen Vogel 2017-07-12 00:57:33 +02:00
parent 11b84deba1
commit 82bc32c206

View file

@ -60,7 +60,7 @@ static int stats_collect_init(struct hook *h)
p->uri = NULL;
p->output = stdout;
return stats_init(&p->stats, p->buckets, p->warmup);
return 0;
}
static int stats_collect_destroy(struct hook *h)
@ -74,15 +74,13 @@ static int stats_collect_start(struct hook *h)
{
struct stats_collect *p = h->_vd;
if (p->uri) {
p->output = fopen(p->uri, "w+");
if (!p->output)
error("Failed to open file %s for writing", p->uri);
}
return 0;
return stats_init(&p->stats, p->buckets, p->warmup);
}
static int stats_collect_stop(struct hook *h)