diff --git a/src/meas_lat.c b/src/meas_lat.c index 2a0fa2c..ebf39be 100644 --- a/src/meas_lat.c +++ b/src/meas_lat.c @@ -96,6 +96,7 @@ int on_timer(struct evt_core_ctx* ctx, struct evt_core_fdinfo* fdinfo) { struct measure_conf* mc = fdinfo->other; s = read(fdinfo->fd, &ticks, sizeof(uint64_t)); + if (s == -1 && errno == EAGAIN) return 0; if (s != sizeof(uint64_t)) { perror("Read error"); exit(EXIT_FAILURE); @@ -124,7 +125,7 @@ int on_timer(struct evt_core_ctx* ctx, struct evt_core_fdinfo* fdinfo) { perror("Send error"); //exit(EXIT_FAILURE); } - return 1; + return 0; }