From f7e68b1766d2400cc8a9b9fe4265ee60a136eec4 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Zden=C4=9Bk=20Salvet?= Date: Fri, 3 Aug 2007 08:22:49 +0000 Subject: [PATCH] User real usernames in proxy, not "lbproxy". --- org.glite.lb.server/src/store.c.T | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/org.glite.lb.server/src/store.c.T b/org.glite.lb.server/src/store.c.T index 28f32c6..f2c1657 100644 --- a/org.glite.lb.server/src/store.c.T +++ b/org.glite.lb.server/src/store.c.T @@ -105,8 +105,15 @@ int edg_wll_StoreEvent(edg_wll_Context ctx,edg_wll_Event *e,int *seq) registered with LBserver */ char *username; - username = (ctx->isProxy) ? "lbproxy" : ctx->peerName; - userid = strdup(strmd5(username, NULL)); + if (!ctx->isProxy && ctx->peerName != NULL) { + username = ctx->peerName; + userid = strdup(strmd5(username, NULL)); + + free(e->any.user); + e->any.user = strdup(username); + } + else + username = e->any.user; if ((err = store_user(ctx,userid, username))) goto clean; if ((err = store_job(ctx,e->any.jobId,userid))) goto clean; } else { -- 1.8.2.3