timerfd_gettime

Returns the next expiration time of fd.

extern (C)
int
timerfd_gettime
(
int fd
,
itimerspec* curr_value
)

Parameters

fd int

file descriptor referring to the timer

curr_value itimerspec*

- it_value: Returns the amount of time until the timer will next expire. If both fields are zero, then the timer is currently disarmed. Contains always a relative value, regardless of whether the TFD_TIMER_ABSTIME flag was specified when setting the timer. - it_interval: Returns the interval of the timer. If both fields are zero, then the timer is set to expire just once, at the time specified by it_value.

Return Value

Type: int

0 on success or -1 on error. Sets errno in case of error.

Meta