shithub: npe

ref: 227d52323d8f98c897a9269e9d4947cf1a28f4bd
dir: /libnpe/gettimeofday.c/

View raw version
#include <time.h>
#include "_npe.h"

int
gettimeofday(struct timeval *tp, struct timezone *tzp)
{
	long long t;

	USED(tzp);
	t = npe_nanosec();
	tp->tv_sec = t / 1000000000ULL;
	tp->tv_usec = (t / 1000ULL)%1000000ULL;

	return 0;
}