2008-12-13 21:28:05 +00:00
|
|
|
/**
|
|
|
|
* This file has no copyright assigned and is placed in the Public Domain.
|
|
|
|
* This file is part of the w64 mingw-runtime package.
|
|
|
|
* No warranty is given; refer to the file DISCLAIMER within this package.
|
|
|
|
*/
|
2013-08-06 21:34:25 +00:00
|
|
|
|
2008-12-13 21:28:05 +00:00
|
|
|
#ifndef _TIME_H__S
|
|
|
|
#define _TIME_H__S
|
|
|
|
|
|
|
|
#include <time.h>
|
|
|
|
|
|
|
|
#if defined(MINGW_HAS_SECURE_API)
|
|
|
|
|
|
|
|
#ifdef __cplusplus
|
|
|
|
extern "C" {
|
|
|
|
#endif
|
|
|
|
|
2013-08-06 21:34:25 +00:00
|
|
|
_Success_(return == 0)
|
|
|
|
_CRTIMP
|
|
|
|
errno_t
|
|
|
|
__cdecl
|
|
|
|
_ctime32_s(
|
|
|
|
_Out_writes_(_SizeInBytes) _Post_readable_size_(26) char *_Buf,
|
|
|
|
_In_ size_t _SizeInBytes,
|
|
|
|
_In_ const __time32_t *_Time);
|
|
|
|
|
|
|
|
_Check_return_wat_
|
|
|
|
_CRTIMP
|
|
|
|
errno_t
|
|
|
|
__cdecl
|
|
|
|
_gmtime32_s(
|
|
|
|
_In_ struct tm *_Tm,
|
|
|
|
_In_ const __time32_t *_Time);
|
|
|
|
|
|
|
|
_CRTIMP
|
|
|
|
errno_t
|
|
|
|
__cdecl
|
|
|
|
_localtime32_s(
|
|
|
|
_Out_ struct tm *_Tm,
|
|
|
|
_In_ const __time32_t *_Time);
|
|
|
|
|
|
|
|
_Check_return_wat_
|
|
|
|
_CRTIMP
|
|
|
|
errno_t
|
|
|
|
__cdecl
|
|
|
|
_strdate_s(
|
|
|
|
_Out_writes_(_SizeInBytes) _Post_readable_size_(9) char *_Buf,
|
|
|
|
_In_range_(>= , 9) size_t _SizeInBytes);
|
|
|
|
|
|
|
|
_Check_return_wat_
|
|
|
|
_CRTIMP
|
|
|
|
errno_t
|
|
|
|
__cdecl
|
|
|
|
_strtime_s(
|
|
|
|
_Out_writes_(_SizeInBytes) _Post_readable_size_(9) char *_Buf,
|
|
|
|
_In_range_(>= , 9) size_t _SizeInBytes);
|
|
|
|
|
|
|
|
_CRTIMP
|
|
|
|
errno_t
|
|
|
|
__cdecl
|
|
|
|
_ctime64_s(
|
|
|
|
_Out_writes_z_(_SizeInBytes) char *_Buf,
|
|
|
|
_In_ size_t _SizeInBytes,
|
|
|
|
_In_ const __time64_t *_Time);
|
|
|
|
|
|
|
|
_CRTIMP
|
|
|
|
errno_t
|
|
|
|
__cdecl
|
|
|
|
_gmtime64_s(
|
|
|
|
_Out_ struct tm *_Tm,
|
|
|
|
_In_ const __time64_t *_Time);
|
|
|
|
|
|
|
|
_CRTIMP
|
|
|
|
errno_t
|
|
|
|
__cdecl
|
|
|
|
_localtime64_s(
|
|
|
|
_Out_ struct tm *_Tm,
|
|
|
|
_In_ const __time64_t *_Time);
|
2008-12-13 21:28:05 +00:00
|
|
|
|
|
|
|
#ifndef _WTIME_S_DEFINED
|
|
|
|
#define _WTIME_S_DEFINED
|
2013-08-06 21:34:25 +00:00
|
|
|
|
|
|
|
_CRTIMP
|
|
|
|
errno_t
|
|
|
|
__cdecl
|
|
|
|
_wasctime_s(
|
|
|
|
_Out_writes_(_SizeInWords) _Post_readable_size_(26) wchar_t *_Buf,
|
|
|
|
_In_range_(>= , 26) size_t _SizeInWords,
|
|
|
|
_In_ const struct tm *_Tm);
|
|
|
|
|
|
|
|
_Success_(return == 0)
|
|
|
|
_CRTIMP
|
|
|
|
errno_t
|
|
|
|
__cdecl
|
|
|
|
_wctime32_s(
|
|
|
|
_Out_writes_(_SizeInWords) _Post_readable_size_(26) wchar_t *_Buf,
|
|
|
|
_In_ size_t _SizeInWords,
|
|
|
|
_In_ const __time32_t *_Time);
|
|
|
|
|
|
|
|
_CRTIMP
|
|
|
|
errno_t
|
|
|
|
__cdecl
|
|
|
|
_wstrdate_s(
|
|
|
|
_Out_writes_(_SizeInWords) _Post_readable_size_(9) wchar_t *_Buf,
|
|
|
|
_In_ size_t _SizeInWords);
|
|
|
|
|
|
|
|
_CRTIMP
|
|
|
|
errno_t
|
|
|
|
__cdecl
|
|
|
|
_wstrtime_s(
|
|
|
|
_Out_writes_(_SizeInWords) _Post_readable_size_(9) wchar_t *_Buf,
|
|
|
|
_In_range_(>= , 9) size_t _SizeInWords);
|
|
|
|
|
|
|
|
_Success_(return == 0)
|
|
|
|
_CRTIMP
|
|
|
|
errno_t
|
|
|
|
__cdecl
|
|
|
|
_wctime64_s(
|
|
|
|
_Out_writes_(_SizeInWords) _Post_readable_size_(26) wchar_t *_Buf,
|
|
|
|
_In_ size_t _SizeInWords,
|
|
|
|
_In_ const __time64_t *_Time);
|
2008-12-13 21:28:05 +00:00
|
|
|
|
|
|
|
#if !defined (RC_INVOKED) && !defined (_INC_WTIME_S_INL)
|
|
|
|
#define _INC_WTIME_S_INL
|
[CRT]
- Update file.c to recent wine. (now with locking!)
- implement/enable __wcserror, __wcserror_s, _access_s, _ctime32_s, _ctime64_s,
_cwprintf, _fseeki64, _ftelli64, _get_osplatform, _get_output_format,
_get_pgmptr, _get_wpgmptr, _get_terminate, _get_tzname, _get_unexpected,
_gmtime64_s, _i64toa_s, _i64tow_s, _initterm_e, _itoa_s, _itow_s,
_localtime32_s, _localtime64_s, _ltoa_s, _ltow_s, _putwch, _searchenv_s,
_sopen_s, _ui64toa_s, _ui64tow_s, _vcwprintf, _vsprintf_p, _waccess_s,
_wcserror, _wcserror_s, _wfopen_s, _wsopen_s, fopen_s, fprintf_s, fwprintf_s,
printf_s, strerror_s, strncpy_s, strtok_s, vfprintf_s, vfwprintf_s, vprintf_s,
vwprintf_s, wcscat_s, wcsncat_s, wcstok_s, wprintf_s. Most code comes from
wine.
- Fix __set_errno -> _set_errno and export it.
- Remove unneeded files.
[CRT_HEADERS]
- add threadmbcinfo struct.
- update some sec_api headers from mingw64 due to missing or incorrect
functions.
Patch by Samuel Serapion.
Changes to msvcrt spec by me due to winebuild.
CRLF/LF fixes.
svn path=/trunk/; revision=54651
2011-12-14 22:09:24 +00:00
|
|
|
errno_t __cdecl _wctime_s(wchar_t *, size_t, const time_t *);
|
|
|
|
#ifndef _USE_32BIT_TIME_T
|
|
|
|
__CRT_INLINE errno_t __cdecl _wctime_s(wchar_t *_Buffer,size_t _SizeInWords,const time_t *_Time) { return _wctime64_s(_Buffer,_SizeInWords,_Time); }
|
2008-12-13 21:28:05 +00:00
|
|
|
#endif
|
|
|
|
#endif
|
2013-08-06 21:34:25 +00:00
|
|
|
|
|
|
|
#endif /* _WTIME_S_DEFINED */
|
2008-12-13 21:28:05 +00:00
|
|
|
|
|
|
|
#ifndef RC_INVOKED
|
|
|
|
#ifdef _USE_32BIT_TIME_T
|
|
|
|
__CRT_INLINE errno_t __cdecl localtime_s(struct tm *_Tm,const time_t *_Time) { return _localtime32_s(_Tm,_Time); }
|
|
|
|
#else
|
|
|
|
__CRT_INLINE errno_t __cdecl localtime_s(struct tm *_Tm,const time_t *_Time) { return _localtime64_s(_Tm,_Time); }
|
|
|
|
#endif
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#ifdef __cplusplus
|
|
|
|
}
|
|
|
|
#endif
|
|
|
|
|
2013-08-06 21:34:25 +00:00
|
|
|
#endif /* MINGW_HAS_SECURE_API */
|
|
|
|
|
|
|
|
#endif /* _TIME_H__S */
|