The clock_gettime function

Name

clock_gettime -- 

Synopsis

#include <pthread.h>

int clock_gettime (int clock_id, struct timespec *tp);

Description

The clock_gettime function gets the time from the given clock.

Returns

The clock_gettime function returns zero if successful and -1 otherwise.

Implementation Notes

The value of clock_id must be CLOCK_REALTIME.