#include <time.h>
unsigned int timeGetTime()
{
unsigned int uptime = 0;
struct timespec on;
if(clock_gettime(CLOCK_MONOTONIC, &on) == 0)
uptime = on.tv_sec*1000 + on.tv_nsec/1000000;
return uptime;
}
移植:timeGetTime() 在linux 下实现
最新推荐文章于 2023-03-20 23:43:26 发布