From 450cfbfe769b0d722ba69a031f96bb1272d3e6a7 Mon Sep 17 00:00:00 2001 From: mquinson Date: Tue, 7 Aug 2007 19:22:58 +0000 Subject: [PATCH] Partially revert previous change: we indeed want a virtualization layer for time(), not a portability one (in other words, we want the time inside the simulator) git-svn-id: svn+ssh://scm.gforge.inria.fr/svn/simgrid/simgrid/trunk@4019 48e7efb5-ca39-0410-a469-dd3cf9ba447f --- src/xbt/xbt_log_layout_format.c | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/src/xbt/xbt_log_layout_format.c b/src/xbt/xbt_log_layout_format.c index 2cf2a0f4b7..86c34f6c78 100644 --- a/src/xbt/xbt_log_layout_format.c +++ b/src/xbt/xbt_log_layout_format.c @@ -12,7 +12,6 @@ #include "xbt/log.h" #include "gras/virtu.h" /* gras_os_myname (KILLME) */ #include "xbt/synchro.h" /* xbt_thread_self_name */ -#include "xbt/xbt_os_time.h" /* xbt_os_time */ #include extern const char *xbt_log_priority_names[7]; @@ -27,7 +26,7 @@ static char *xbt_log_layout_format_doit(xbt_log_layout_t l, int precision=-1; if (begin_of_time<0) - begin_of_time=xbt_os_time(); + begin_of_time=gras_os_time(); p = res; q = l->data; @@ -176,17 +175,17 @@ static char *xbt_log_layout_format_doit(xbt_log_layout_t l, case 'd': /* date; LOG4J compliant */ if (precision == -1) - p += sprintf(p,"%f", xbt_os_time()); + p += sprintf(p,"%f", gras_os_time()); else { - p += sprintf(p,"%.*f", precision, xbt_os_time()); + p += sprintf(p,"%.*f", precision, gras_os_time()); precision = -1; } break; case 'r': /* application age; LOG4J compliant */ if (precision == -1) - p += sprintf(p,"%f", xbt_os_time()-begin_of_time); + p += sprintf(p,"%f", gras_os_time()-begin_of_time); else { - p += sprintf(p,"%.*f", precision, xbt_os_time()-begin_of_time); + p += sprintf(p,"%.*f", precision, gras_os_time()-begin_of_time); precision = -1; } break; -- 2.20.1