aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Barcroft <mike@FreeBSD.org>2003-02-26 16:50:01 +0000
committerMike Barcroft <mike@FreeBSD.org>2003-02-26 16:50:01 +0000
commit832b6bd471145292bed2bcd64e37c118601f29a3 (patch)
treedcfe3f8d0e14b9d7fba13d98c2b3e00bbad2c440
parent33673595a675f5c76947e469fcb8b8d66071a38c (diff)
downloadsrc-832b6bd471145292bed2bcd64e37c118601f29a3.tar.gz
src-832b6bd471145292bed2bcd64e37c118601f29a3.zip
Simplify struct __timespec, fix style bugs, add an XXX comment.
Submitted by: bde
Notes
Notes: svn path=/head/; revision=111557
-rw-r--r--sys/sys/_timespec.h19
1 files changed, 10 insertions, 9 deletions
diff --git a/sys/sys/_timespec.h b/sys/sys/_timespec.h
index 48cef5a24986..49881506f5ad 100644
--- a/sys/sys/_timespec.h
+++ b/sys/sys/_timespec.h
@@ -36,25 +36,26 @@
*/
/*
- * Prerequisites: <sys/cdefs.h>, <sys/_types.h>
+ * Prerequisite: <sys/_types.h>
*
* This file must be kept synchronized with <sys/timespec.h>.
* It defines a structure which must be a type pun for
* `struct timespec'; this structure is used in header files where
* the ABI uses a `struct timespec' but standards prohibit its
* definition. (Currently only <sys/stat.h>.)
+ *
+ * XXX should just declare struct __timespec as necessary. It's simple,
+ * so is easy to keep synchronized, and hopefully not needed in as many
+ * places as struct timespec, so we don't need this extra header.
+ * Perhaps we don't need timespec.h either.
*/
#ifndef _SYS__TIMESPEC_H_
-#define _SYS__TIMESPEC_H_
+#define _SYS__TIMESPEC_H_
struct __timespec {
-#ifndef _TIME_T_DECLARED
- __time_t __tv_sec; /* seconds, but time_t is not yet defined */
-#else
- time_t __tv_sec; /* seconds */
-#endif
- long __tv_nsec; /* and nanoseconds */
+ __time_t tv_sec; /* seconds */
+ long tv_nsec; /* and nanoseconds */
};
-#endif /* _SYS__TIMESPEC_H_ */
+#endif /* !_SYS__TIMESPEC_H_ */