Skip to content

Commit

Permalink
fixed get_current_time()
Browse files Browse the repository at this point in the history
  • Loading branch information
wangyu- committed Nov 24, 2017
1 parent 5f0a16c commit 4d3b713
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion common.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ u64_t get_current_time()//ms
{
timespec tmp_time;
clock_gettime(CLOCK_MONOTONIC, &tmp_time);
return tmp_time.tv_sec*1000+tmp_time.tv_nsec/(1000*1000l);
return ((u64_t)tmp_time.tv_sec)*1000llu+((u64_t)tmp_time.tv_nsec)/(1000*1000llu);
}

u64_t get_current_time_us()
Expand Down

0 comments on commit 4d3b713

Please sign in to comment.