Include time.h with __need_timespec even if __USE_MISC is defined but __USE_XOPEN...
authorAndreas Jaeger <aj@suse.de>
Thu, 2 Jan 2003 07:51:18 +0000 (07:51 +0000)
committerAndreas Jaeger <aj@suse.de>
Thu, 2 Jan 2003 07:51:18 +0000 (07:51 +0000)
io/sys/stat.h

index 3136dd9..24e7fe3 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (C) 1991,1992,1995-2001,2002 Free Software Foundation, Inc.
+/* Copyright (C) 1991,1992,1995-2002,2003 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
    The GNU C Library is free software; you can redistribute it and/or
 
 #include <bits/types.h>                /* For __mode_t and __dev_t.  */
 
-#ifdef __USE_XOPEN
+#if defined __USE_XOPEN || defined __USE_MISC
+# ifdef __USE_XOPEN
+#  define __need_time_t
+# endif
 # ifdef __USE_MISC
 #  define __need_timespec
 # endif
-# define __need_time_t
-# include <time.h>             /* For time_t.  */
+# include <time.h>             /* For time_t resp. timespec.  */
+#endif
 
+#ifdef __USE_XOPEN
 /* The Single Unix specification says that some more types are
    available here.  */
 # ifndef __dev_t_defined