Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
We want time in seconds.
authorpini <pini@48e7efb5-ca39-0410-a469-dd3cf9ba447f>
Tue, 6 Apr 2010 08:39:02 +0000 (08:39 +0000)
committerpini <pini@48e7efb5-ca39-0410-a469-dd3cf9ba447f>
Tue, 6 Apr 2010 08:39:02 +0000 (08:39 +0000)
git-svn-id: svn+ssh://scm.gforge.inria.fr/svn/simgrid/simgrid/trunk@7436 48e7efb5-ca39-0410-a469-dd3cf9ba447f

src/xbt/xbt_os_time.c

index 3b0a26b..a7f17f5 100644 (file)
@@ -127,7 +127,7 @@ double xbt_os_timer_elapsed(xbt_os_timer_t timer)
 #ifdef HAVE_POSIX_GETTIME
   return ((double) timer->stop.tv_sec) - ((double) timer->start.tv_sec) +
       ((((double) timer->stop.tv_nsec) -
-        ((double) timer->start.tv_nsec)) / 1e-9);
+        ((double) timer->start.tv_nsec)) / 1e9);
 #elif defined(HAVE_GETTIMEOFDAY)
   return ((double) timer->stop.tv_sec) - ((double) timer->start.tv_sec) +
     ((((double) timer->stop.tv_usec) -