Skip to content

Commit 4d3b713

Browse files
committed
fixed get_current_time()
1 parent 5f0a16c commit 4d3b713

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

common.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ u64_t get_current_time()//ms
5252
{
5353
timespec tmp_time;
5454
clock_gettime(CLOCK_MONOTONIC, &tmp_time);
55-
return tmp_time.tv_sec*1000+tmp_time.tv_nsec/(1000*1000l);
55+
return ((u64_t)tmp_time.tv_sec)*1000llu+((u64_t)tmp_time.tv_nsec)/(1000*1000llu);
5656
}
5757

5858
u64_t get_current_time_us()

0 commit comments

Comments
 (0)