OSDN Git Service

Remove time_t definition from wchar.h and change _findfrist* and _findnext* to __CRT_...
authorEarnie Boyd <earnie@users.sourceforge.net>
Wed, 19 Jun 2013 15:21:41 +0000 (11:21 -0400)
committerEarnie Boyd <earnie@users.sourceforge.net>
Wed, 19 Jun 2013 15:21:41 +0000 (11:21 -0400)
ChangeLog
include/io.h
include/sys/types.h
include/wchar.h

index 265696e..36ad7f3 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,11 @@
+2013-06-18  Earnie Boyd  <earnie@users.sourceforge.net>
+
+       * include/io.h (_findfirst*, _findnext*): Remove the __NO_INLINE__
+       filter and change the signature to __CRT_MAYBE_INLINE.
+       * include/wchar.h (time_t): Remove definition.
+       * include/sys/types.h: Add comment for time_t indicating other files
+       where time_t is defined.
+
 2013-06-17  Earnie Boyd  <earnie@users.sourceforge.net>
 
        * include/_mingw.h (__CRT_MAYBE_INLINE): When __NO_INLINE__ defined we
index 3f32528..271d928 100644 (file)
@@ -232,9 +232,8 @@ _CRTIMP int __cdecl __MINGW_NOTHROW _findnext64(intptr_t, struct __finddata64_t*
 int __cdecl __MINGW_NOTHROW _findnext32i64(intptr_t, struct _finddata32i64_t*);
 int __cdecl __MINGW_NOTHROW _findnext64i32(intptr_t, struct _finddata64i32_t*);
 
-#ifndef __NO_INLINE__
 #include <string.h>
-__CRT_INLINE __cdecl __MINGW_NOTHROW intptr_t _findfirst32i64(const char* _filename, struct _finddata32i64_t* _fdata) {
+__CRT_MAYBE_INLINE __cdecl __MINGW_NOTHROW intptr_t _findfirst32i64(const char* _filename, struct _finddata32i64_t* _fdata) {
     struct __finddata64_t fd;
     intptr_t ret = _findfirst64(_filename, &fd);
     if (ret == -1) {
@@ -250,7 +249,7 @@ __CRT_INLINE __cdecl __MINGW_NOTHROW intptr_t _findfirst32i64(const char* _filen
     return ret;
 }
 
-__CRT_INLINE __cdecl __MINGW_NOTHROW intptr_t _findfirst64i32(const char* _filename, struct _finddata64i32_t* _fdata) {
+__CRT_MAYBE_INLINE __cdecl __MINGW_NOTHROW intptr_t _findfirst64i32(const char* _filename, struct _finddata64i32_t* _fdata) {
     struct _finddata32_t fd;
     intptr_t ret = _findfirst32(_filename, &fd);
     if (ret == -1) {
@@ -266,7 +265,7 @@ __CRT_INLINE __cdecl __MINGW_NOTHROW intptr_t _findfirst64i32(const char* _filen
     return ret;
 }
 
-__CRT_INLINE __cdecl __MINGW_NOTHROW intptr_t _findnext32i64(intptr_t _fp, struct _finddata32i64_t* _fdata) {
+__CRT_MAYBE_INLINE __cdecl __MINGW_NOTHROW intptr_t _findnext32i64(intptr_t _fp, struct _finddata32i64_t* _fdata) {
     struct __finddata64_t fd;
     int ret = _findnext64(_fp,&fd);
     if (ret == -1) {
@@ -282,7 +281,7 @@ __CRT_INLINE __cdecl __MINGW_NOTHROW intptr_t _findnext32i64(intptr_t _fp, struc
     return ret;
 }
 
-__CRT_INLINE __cdecl __MINGW_NOTHROW intptr_t _findnext64i32(intptr_t _fp, struct _finddata64i32_t* _fdata) {
+__CRT_MAYBE_INLINE __cdecl __MINGW_NOTHROW intptr_t _findnext64i32(intptr_t _fp, struct _finddata64i32_t* _fdata) {
     struct _finddata32_t fd;
     int ret = _findnext32(_fp, &fd);
     if (ret == -1) {
@@ -297,12 +296,6 @@ __CRT_INLINE __cdecl __MINGW_NOTHROW intptr_t _findnext64i32(intptr_t _fp, struc
     strncpy(_fdata->name, fd.name, FILENAME_MAX);
     return ret;
 }
-#else /* def __NO_INLINE__ */
-#define _findfirst64i32 _findfirst64
-#define _findfirst32i64 _findfirst32
-#define _findnext64i32 _findnext64
-#define _findnext32i64 _findnext32
-#endif /* ndef __NO_INLINE__ */
 
 #ifndef __NO_MINGW_LFS
 __CRT_INLINE off64_t lseek64 (int, off64_t, int);
index 1c16260..9c7fcf9 100644 (file)
 
 #ifndef RC_INVOKED
 
+/*
+ * A type for storing the current time and date. This is the number of
+ * seconds since midnight Jan 1, 1970.
+ * NOTE: This is also defined in time.h.
+ */
 #ifndef _TIME32_T_DEFINED
 typedef __int32 __time32_t;
 #define _TIME32_T_DEFINED
index 233941c..1a1c461 100644 (file)
@@ -84,11 +84,6 @@ typedef struct _iobuf
 } FILE;
 #endif /* Not _FILE_DEFINED */
 
-#ifndef _TIME_T_DEFINED  /* Also in time.h */
-typedef long time_t;
-#define _TIME_T_DEFINED
-#endif
-
 #ifndef _TM_DEFINED /* Also in time.h */
 struct tm {
         int tm_sec;     /* seconds after the minute - [0,59] */