提交 6c78e3d5 编写于 作者: R rriggs

8215976: Fix gmtime_r declaration conflicts in zip.cpp with linux header files

Reviewed-by: dholmes, rriggs
Contributed-by: patrick@os.amperecomputing.com
上级 0714d479
......@@ -415,9 +415,11 @@ uLong jar::dostime(int y, int n, int d, int h, int m, int s) {
((uLong)h << 11) | ((uLong)m << 5) | ((uLong)s >> 1);
}
#ifdef _REENTRANT // solaris
extern "C" struct tm *gmtime_r(const time_t *, struct tm *);
#else
/*
* For thread-safe reasons, non-Windows platforms need gmtime_r
* while Windows can directly use gmtime that is already thread-safe.
*/
#ifdef _MSC_VER
#define gmtime_r(t, s) gmtime(t)
#endif
/*
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册