clang-format changed files

pull/2289/head
Craig Tiller 10 years ago
parent 63a4e22713
commit 87d2cac981
  1. 12
      src/core/support/time_win32.c

@ -58,12 +58,12 @@ gpr_timespec gpr_now(gpr_clock_type clock) {
double now_dbl; double now_dbl;
switch (clock) { switch (clock) {
case GPR_CLOCK_REALTIME: case GPR_CLOCK_REALTIME:
_ftime_s(&now_tb); _ftime_s(&now_tb);
now_tv.tv_sec = now_tb.time; now_tv.tv_sec = now_tb.time;
now_tv.tv_nsec = now_tb.millitm * 1000000; now_tv.tv_nsec = now_tb.millitm * 1000000;
break; break;
case GPR_CLOCK_MONOTONIC: case GPR_CLOCK_MONOTONIC:
QueryPerformanceCounter(&timestamp); QueryPerformanceCounter(&timestamp);
now_dbl = (timestamp.QuadPart - g_start_time.QuadPart) * g_time_scale; now_dbl = (timestamp.QuadPart - g_start_time.QuadPart) * g_time_scale;
now_tv.tv_sec = (time_t)now_dbl; now_tv.tv_sec = (time_t)now_dbl;
now_tv.tv_nsec = (int)((now_dbl - (double)now_tv.tv_sec) * 1e9); now_tv.tv_nsec = (int)((now_dbl - (double)now_tv.tv_sec) * 1e9);

Loading…
Cancel
Save