sys/timeb.h@3:0c3bcea5b4d0, 2012-03-05 (annotated)
- Committer:
- sca8er
- Date:
- Mon Mar 05 04:56:58 2012 +0000
- Revision:
- 3:0c3bcea5b4d0
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
sca8er | 3:0c3bcea5b4d0 | 1 | /* |
sca8er | 3:0c3bcea5b4d0 | 2 | * timeb.h |
sca8er | 3:0c3bcea5b4d0 | 3 | * This file has no copyright assigned and is placed in the Public Domain. |
sca8er | 3:0c3bcea5b4d0 | 4 | * This file is a part of the mingw-runtime package. |
sca8er | 3:0c3bcea5b4d0 | 5 | * No warranty is given; refer to the file DISCLAIMER within the package. |
sca8er | 3:0c3bcea5b4d0 | 6 | * |
sca8er | 3:0c3bcea5b4d0 | 7 | * Support for the UNIX System V ftime system call. |
sca8er | 3:0c3bcea5b4d0 | 8 | * |
sca8er | 3:0c3bcea5b4d0 | 9 | */ |
sca8er | 3:0c3bcea5b4d0 | 10 | |
sca8er | 3:0c3bcea5b4d0 | 11 | #ifndef _TIMEB_H_ |
sca8er | 3:0c3bcea5b4d0 | 12 | #define _TIMEB_H_ |
sca8er | 3:0c3bcea5b4d0 | 13 | |
sca8er | 3:0c3bcea5b4d0 | 14 | /* All the headers include this file. */ |
sca8er | 3:0c3bcea5b4d0 | 15 | #include <_mingw.h> |
sca8er | 3:0c3bcea5b4d0 | 16 | #include <sys/types.h> |
sca8er | 3:0c3bcea5b4d0 | 17 | |
sca8er | 3:0c3bcea5b4d0 | 18 | #ifndef RC_INVOKED |
sca8er | 3:0c3bcea5b4d0 | 19 | |
sca8er | 3:0c3bcea5b4d0 | 20 | /* |
sca8er | 3:0c3bcea5b4d0 | 21 | * TODO: Structure not tested. |
sca8er | 3:0c3bcea5b4d0 | 22 | */ |
sca8er | 3:0c3bcea5b4d0 | 23 | struct _timeb |
sca8er | 3:0c3bcea5b4d0 | 24 | { |
sca8er | 3:0c3bcea5b4d0 | 25 | time_t time; |
sca8er | 3:0c3bcea5b4d0 | 26 | short millitm; |
sca8er | 3:0c3bcea5b4d0 | 27 | short timezone; |
sca8er | 3:0c3bcea5b4d0 | 28 | short dstflag; |
sca8er | 3:0c3bcea5b4d0 | 29 | }; |
sca8er | 3:0c3bcea5b4d0 | 30 | |
sca8er | 3:0c3bcea5b4d0 | 31 | #if __MSVCRT_VERSION__ >= 0x0800 |
sca8er | 3:0c3bcea5b4d0 | 32 | /* |
sca8er | 3:0c3bcea5b4d0 | 33 | * TODO: Structure not tested. |
sca8er | 3:0c3bcea5b4d0 | 34 | */ |
sca8er | 3:0c3bcea5b4d0 | 35 | struct __timeb32 |
sca8er | 3:0c3bcea5b4d0 | 36 | { |
sca8er | 3:0c3bcea5b4d0 | 37 | __time32_t time; |
sca8er | 3:0c3bcea5b4d0 | 38 | short millitm; |
sca8er | 3:0c3bcea5b4d0 | 39 | short timezone; |
sca8er | 3:0c3bcea5b4d0 | 40 | short dstflag; |
sca8er | 3:0c3bcea5b4d0 | 41 | }; |
sca8er | 3:0c3bcea5b4d0 | 42 | #endif /* __MSVCRT_VERSION__ >= 0x0800 */ |
sca8er | 3:0c3bcea5b4d0 | 43 | |
sca8er | 3:0c3bcea5b4d0 | 44 | #ifndef _NO_OLDNAMES |
sca8er | 3:0c3bcea5b4d0 | 45 | /* |
sca8er | 3:0c3bcea5b4d0 | 46 | * TODO: Structure not tested. |
sca8er | 3:0c3bcea5b4d0 | 47 | */ |
sca8er | 3:0c3bcea5b4d0 | 48 | struct timeb |
sca8er | 3:0c3bcea5b4d0 | 49 | { |
sca8er | 3:0c3bcea5b4d0 | 50 | time_t time; |
sca8er | 3:0c3bcea5b4d0 | 51 | short millitm; |
sca8er | 3:0c3bcea5b4d0 | 52 | short timezone; |
sca8er | 3:0c3bcea5b4d0 | 53 | short dstflag; |
sca8er | 3:0c3bcea5b4d0 | 54 | }; |
sca8er | 3:0c3bcea5b4d0 | 55 | #endif |
sca8er | 3:0c3bcea5b4d0 | 56 | |
sca8er | 3:0c3bcea5b4d0 | 57 | #ifdef __cplusplus |
sca8er | 3:0c3bcea5b4d0 | 58 | extern "C" { |
sca8er | 3:0c3bcea5b4d0 | 59 | #endif |
sca8er | 3:0c3bcea5b4d0 | 60 | |
sca8er | 3:0c3bcea5b4d0 | 61 | /* TODO: Not tested. */ |
sca8er | 3:0c3bcea5b4d0 | 62 | _CRTIMP void __cdecl __MINGW_NOTHROW _ftime (struct _timeb*); |
sca8er | 3:0c3bcea5b4d0 | 63 | |
sca8er | 3:0c3bcea5b4d0 | 64 | #ifndef _NO_OLDNAMES |
sca8er | 3:0c3bcea5b4d0 | 65 | /* FIXME for __MSVCRT_VERSION__ >= 0x0800 */ |
sca8er | 3:0c3bcea5b4d0 | 66 | _CRTIMP void __cdecl __MINGW_NOTHROW ftime (struct timeb*); |
sca8er | 3:0c3bcea5b4d0 | 67 | #endif /* Not _NO_OLDNAMES */ |
sca8er | 3:0c3bcea5b4d0 | 68 | |
sca8er | 3:0c3bcea5b4d0 | 69 | /* This requires newer versions of msvcrt.dll (6.10 or higher). */ |
sca8er | 3:0c3bcea5b4d0 | 70 | #if __MSVCRT_VERSION__ >= 0x0601 |
sca8er | 3:0c3bcea5b4d0 | 71 | struct __timeb64 |
sca8er | 3:0c3bcea5b4d0 | 72 | { |
sca8er | 3:0c3bcea5b4d0 | 73 | __time64_t time; |
sca8er | 3:0c3bcea5b4d0 | 74 | short millitm; |
sca8er | 3:0c3bcea5b4d0 | 75 | short timezone; |
sca8er | 3:0c3bcea5b4d0 | 76 | short dstflag; |
sca8er | 3:0c3bcea5b4d0 | 77 | }; |
sca8er | 3:0c3bcea5b4d0 | 78 | |
sca8er | 3:0c3bcea5b4d0 | 79 | _CRTIMP void __cdecl __MINGW_NOTHROW _ftime64 (struct __timeb64*); |
sca8er | 3:0c3bcea5b4d0 | 80 | #endif /* __MSVCRT_VERSION__ >= 0x0601 */ |
sca8er | 3:0c3bcea5b4d0 | 81 | |
sca8er | 3:0c3bcea5b4d0 | 82 | #if __MSVCRT_VERSION__ >= 0x0800 |
sca8er | 3:0c3bcea5b4d0 | 83 | _CRTIMP void __cdecl __MINGW_NOTHROW _ftime32 (struct __timeb32*); |
sca8er | 3:0c3bcea5b4d0 | 84 | #ifndef _USE_32BIT_TIME_T |
sca8er | 3:0c3bcea5b4d0 | 85 | _CRTALIAS void __cdecl __MINGW_NOTHROW _ftime (struct _timeb* _v) { return(_ftime64 ((struct __timeb64*)_v)); } |
sca8er | 3:0c3bcea5b4d0 | 86 | #else |
sca8er | 3:0c3bcea5b4d0 | 87 | _CRTALIAS void __cdecl __MINGW_NOTHROW _ftime (struct _timeb* _v) { return(_ftime32 ((struct __timeb32*)_v)); } |
sca8er | 3:0c3bcea5b4d0 | 88 | #endif |
sca8er | 3:0c3bcea5b4d0 | 89 | #endif /* __MSVCRT_VERSION__ >= 0x0800 */ |
sca8er | 3:0c3bcea5b4d0 | 90 | |
sca8er | 3:0c3bcea5b4d0 | 91 | #ifdef __cplusplus |
sca8er | 3:0c3bcea5b4d0 | 92 | } |
sca8er | 3:0c3bcea5b4d0 | 93 | #endif |
sca8er | 3:0c3bcea5b4d0 | 94 | |
sca8er | 3:0c3bcea5b4d0 | 95 | #endif /* Not RC_INVOKED */ |
sca8er | 3:0c3bcea5b4d0 | 96 | |
sca8er | 3:0c3bcea5b4d0 | 97 | #endif /* Not _TIMEB_H_ */ |