This is the mail archive of the
mailing list for the Java project.
Re: Patch: FYI: System.nanoTime
- From: Tom Tromey <tromey at redhat dot com>
- To: Cédric Berger <cedric at berger dot to>
- Cc: java-patches at gcc dot gnu dot org
- Date: 10 Mar 2006 17:35:35 -0700
- Subject: Re: Patch: FYI: System.nanoTime
- References: <email@example.com>
- Reply-to: tromey at redhat dot com
>>>>> "Cédric" == Cédric Berger <firstname.lastname@example.org> writes:
Cédric> + if (clock_gettime (CLOCK_REALTIME, &now) == 0)
Cédric> Why do you use CLOCK_REALTIME?
Just ignorance I'm afraid.
Cédric> The problem is when you use CLOCK_REALTIME to measure
Cédric> elapsed time and the user changes the time...
Cédric> I had to write the same code for another project, and
Cédric> I used the following snipped for Linux/BSD/Solaris:
Thanks. I will change it to something like this next week.