mirror of
https://github.com/0intro/wmii
synced 2024-11-25 15:20:15 +03:00
14 lines
251 B
C
14 lines
251 B
C
/* Written by Kris Maglione <maglione.k at Gmail> */
|
|
/* Public domain */
|
|
#include "util.h"
|
|
#include <sys/time.h>
|
|
|
|
uvlong
|
|
nsec(void) {
|
|
struct timeval tv;
|
|
|
|
gettimeofday(&tv, nil);
|
|
return (uvlong)tv.tv_sec * 1000000000 + (uvlong)tv.tv_usec * 1000;
|
|
}
|
|
|