Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
};
struct fireperf_stats stats = { 0 };
int r;
+ int timerfd = -1;
// Parse command line
r = parse_argv(argc, argv, &conf);
}
// Create timerfd() to print statistics
- int timerfd = timerfd_create(CLOCK_MONOTONIC, TFD_NONBLOCK|TFD_CLOEXEC);
+ timerfd = timerfd_create(CLOCK_MONOTONIC, TFD_NONBLOCK|TFD_CLOEXEC);
if (timerfd < 0) {
ERROR(&conf, "timerfd_create() failed: %s\n", strerror(errno));
r = 1;
return r;
}
-
int fireperf_dump_stats(struct fireperf_config* conf, struct fireperf_stats* stats, int mode) {
struct timespec now;