From bd44c96e0ffc02fd4905d968c8ecaf308a259891 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Ale=C5=A1=20K=C5=99enek?= Date: Fri, 9 Sep 2005 06:48:16 +0000 Subject: [PATCH] cleanup of timsetamps vs. attr values --- org.glite.lb.server/src/lb_plugin.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/org.glite.lb.server/src/lb_plugin.c b/org.glite.lb.server/src/lb_plugin.c index 1b850a7..97842a4 100644 --- a/org.glite.lb.server/src/lb_plugin.c +++ b/org.glite.lb.server/src/lb_plugin.c @@ -13,6 +13,8 @@ #include "glite/lb/events.h" #include "glite/lb/events_parse.h" +#include "glite/lb/trio.h" + //#include "jobstat.h" #include "glite/jp/types.h" @@ -214,6 +216,8 @@ static int lb_query(void *fpctx,void *handle,const char *attr,glite_jp_attrval_t av[0].name = strdup(GLITE_JP_ATTR_OWNER); av[0].value = strdup(h->events[i]->any.user); av[0].size = -1; + av[0].timestamp = + h->events[i]->any.timestamp.tv_sec; break; } @@ -230,6 +234,9 @@ static int lb_query(void *fpctx,void *handle,const char *attr,glite_jp_attrval_t { av = calloc(2, sizeof(glite_jp_attrval_t)); av[0].name = strdup(GLITE_JP_LB_SUBMITTED); + trio_asprintf(&av[0].value,"%ld.%06ld", + h->events[i]->any.timestamp.tv_sec, + h->events[i]->any.timestamp.tv_usec); av[0].timestamp = h->events[i]->any.timestamp.tv_sec; -- 1.8.2.3