From c2693c327b019dde40d2331c330ec7a1de20a2b6 Mon Sep 17 00:00:00 2001 From: Jan Nitjmans Date: Fri, 7 Jun 2013 18:47:09 -0400 Subject: [PATCH 1/1] include/time.h: Correct typos. Add MSVCRT_VERSION >= 800 guard for _CRTALIAS of _wctime. --- ChangeLog | 5 +++++ include/time.h | 22 ++++++++++++++-------- 2 files changed, 19 insertions(+), 8 deletions(-) diff --git a/ChangeLog b/ChangeLog index 99b72f0..991f94c 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2013-06-07 Jan Nijtmans + + * include/time.h: Correct typos. Add MSVCRT_VERSION >= 800 guard for + _CRTALIAS of _wctime. + 2013-06-05 Mark * include/shlobj.h (SHGetFolderPath): Correct typo for UNICODE define. diff --git a/include/time.h b/include/time.h index 5578518..ca55701 100644 --- a/include/time.h +++ b/include/time.h @@ -247,21 +247,27 @@ __MINGW_IMPORT char *tzname[2]; _CRTIMP wchar_t* __cdecl __MINGW_NOTHROW _wasctime(const struct tm*); _CRTIMP wchar_t* __cdecl __MINGW_NOTHROW _wstrdate(wchar_t*); _CRTIMP wchar_t* __cdecl __MINGW_NOTHROW _wstrtime(wchar_t*); -_CRTIMP wchar_t* __cdecl __MINGW_NOTHROW _wctime(const time_t*); -_CRTIMP wchar_t* __cdecl __MINGW_NOTHROW _wctime64 (const __time64_t*); -#ifdef MSVCRT_VERSION >= 800 -_CRTIMP wchar_t* __cdecl __MINGW_NOTHROW _wctime32 (const __time32_t*); +_CRTIMP wchar_t* __cdecl __MINGW_NOTHROW _wctime64(const __time64_t*); +#if MSVCRT_VERSION >= 800 +_CRTIMP wchar_t* __cdecl __MINGW_NOTHROW _wctime32(const __time32_t*); #else -_CRTALIAS whcar_t* __cdecl __MINGW_NOTHROW _wctime32 (const __time32_t* _v) { +_CRTIMP wchar_t* __cdecl __MINGW_NOTHROW _wctime(const time_t*); +_CRTALIAS wchar_t* __cdecl __MINGW_NOTHROW _wctime32(const __time32_t* _v) { return(_wctime((time_t)_v)); } #endif /* MSVCRT_VERSION >= 800 */ #ifdef _USE_32BIT_TIME_T -_CRTALIAS wchar_t* __cdecl __MINGW_NOTHROW _wctime (const time_t* _v) { return(_wctime32 (_v)); } -#else -_CRTALIAS wchar_t* __cdecl __MINGW_NOTHROW _wctime (const time_t* _v) { return(_wctime64 (_v)); } +#if MSVCRT_VERSION >= 800 +_CRTALIAS wchar_t* __cdecl __MINGW_NOTHROW _wctime (const time_t* _v) { + return(_wctime32 (_v)); +} #endif +#else /* ndef _USE_32BIT_TIME_T */ +_CRTALIAS wchar_t* __cdecl __MINGW_NOTHROW _wctime (const time_t* _v) { + return(_wctime64 (_v)); +} +#endif /* def _USE_32BIT_TIME_T */ #endif /* __STRICT_ANSI__ */ -- 2.11.0