github.com/afumu/libc@v0.0.6/musl/src/time/timespec_get.c (about)

     1  #include <time.h>
     2  
     3  /* There is no other implemented value than TIME_UTC; all other values
     4   * are considered erroneous. */
     5  int timespec_get(struct timespec * ts, int base)
     6  {
     7  	if (base != TIME_UTC) return 0;
     8  	int ret = __clock_gettime(CLOCK_REALTIME, ts);
     9  	return ret < 0 ? 0 : base;
    10  }