Date: Mon, 25 Nov 2002 05:51:22 +0000 From: Hiten Pandya <hiten@unixdaemons.com> To: Bruce Evans <bde@zeta.org.au> Cc: Mike Barcroft <mike@FreeBSD.ORG>, freebsd-standards@FreeBSD.ORG Subject: Re: CLOCK_REALTIME and TIME_ABSTIME missing from time.h Message-ID: <3DE1BA5A.5020302@unixdaemons.com> References: <20021124160549.G52232-100000@gamplex.bde.org>
next in thread | previous in thread | raw e-mail | index | archive | help
Bruce Evans wrote: > On Sat, 23 Nov 2002, Mike Barcroft wrote: > > >>Hiten Pandya <hiten@unixdaemons.com> writes: >> >>>Hello. >>> >>>After doing some work on posixtest, I have found out, that time.h is >>>missing CLOCK_REALTIME, and TIME_ABSTIME. Is there a reason to why >>>we dont have these #define's? >> >>They are listed as TMR (Timer) options in POSIX. We don't currently >>support this option. > > > TIME_ABSTIME seems to be a misspelling of TIMER_ABSTIME. Neither is > supported, so they probably shouldn't be defined. But TIMER_ABSTIME > is defined in a wrong place (<sys/time.h>). > > CLOCK_REALTIME is the only CLOCK_* timer that is supported. It is > defined in a wrong place (<sys/time.h>). In needed to "fix" this when > I fixed the namespace pollution of including <sys/time.h> in > <sys/stat.h>. The following patch doesn't fix the misplacement of > things in <sys/time.h>: > > %%% > Index: time.h > =================================================================== > RCS file: /home/ncvs/src/include/time.h,v > retrieving revision 1.30 > diff -u -2 -r1.30 time.h > --- time.h 6 Sep 2002 11:23:32 -0000 1.30 > +++ time.h 6 Sep 2002 12:43:56 -0000 > @@ -64,4 +62,13 @@ > #endif > > +#if __POSIX_VISIBLE >= 199309 > +#define CLOCK_REALTIME 0 > +#define CLOCK_VIRTUAL 1 > +#define CLOCK_PROF 2 > + > +#define TIMER_RELTIME 0x0 /* relative timer */ > +#define TIMER_ABSTIME 0x1 /* absolute timer */ > +#endif > + > #ifndef _CLOCK_T_DECLARED > typedef __clock_t clock_t; > %%% > > Bruce > > . Hi Bruce Is this going to be committed, or ...? -- Hiten hiten@unixdaemons.com, hiten@uk.FreeBSD.org, hiten@softweyr.com To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-standards" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?3DE1BA5A.5020302>