diff --git a/src/event.cc b/src/event.cc index 59033388eea..66572f3484c 100644 --- a/src/event.cc +++ b/src/event.cc @@ -204,7 +204,7 @@ EventScheduler::timeRemaining() const if (tasks->when <= current_dtime) // we are on time or late return 0; // fire the event ASAP - const double diff = tasks->when - current_dtime; // microseconds + const double diff = tasks->when - current_dtime; // seconds // Round UP: If we come back a nanosecond earlier, we will wait again! const int timeLeft = static_cast(ceil(1000*diff)); // milliseconds // Avoid hot idle: A series of rapid select() calls with zero timeout.