浏览代码

Fix compilation warning on MSVC

Paul-Louis Ageneau 1 年之前
父节点
当前提交
5515f71539
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      examples/streamer/helpers.cpp

+ 1 - 1
examples/streamer/helpers.cpp

@@ -38,7 +38,7 @@ int gettimeofday(struct timeval *tv, struct timezone *tz) {
 		x.LowPart = filetime.dwLowDateTime;
 		x.HighPart = filetime.dwHighDateTime;
 		usec = x.QuadPart / 10 - epoch_offset_us;
-		tv->tv_sec = time_t(usec / 1000000ULL);
+		tv->tv_sec = long(usec / 1000000ULL);
 		tv->tv_usec = long(usec % 1000000ULL);
 	}
 	if (tz) {