From: Zdeněk Salvet Date: Wed, 25 Apr 2007 12:51:35 +0000 (+0000) Subject: Pass error from intJobStatus upwards (should fix bug #25872). X-Git-Tag: merge_30_31_dst5~1 X-Git-Url: http://scientific.zcu.cz/git/?a=commitdiff_plain;h=4dce4d8ee952d07fe1424e9c443a3a7b8e429b5d;p=jra1mw.git Pass error from intJobStatus upwards (should fix bug #25872). --- diff --git a/org.glite.lb.server/src/jobstat.c b/org.glite.lb.server/src/jobstat.c index 052bb62..49f4c93 100644 --- a/org.glite.lb.server/src/jobstat.c +++ b/org.glite.lb.server/src/jobstat.c @@ -85,6 +85,7 @@ int edg_wll_JobStatus( #if DAG_ENABLE char *stmt = NULL; #endif + char *errdesc = NULL; //The following declarations have originally been positioned in the funcion's code //That was rather messy and lead to redeclaratios :-( char *stat_str, *s_out; @@ -139,6 +140,7 @@ int edg_wll_JobStatus( } else { lockErr = edg_wll_LockJob(ctx,job); intErr = edg_wll_intJobStatus(ctx, job, flags,&jobstat, js_enable_store && !lockErr); + if (intErr) edg_wll_Error(ctx, NULL, &errdesc); if (!lockErr) { edg_wll_UnlockJob(ctx,job); } @@ -152,7 +154,9 @@ int edg_wll_JobStatus( free(string_jobid); free(md5_jobid); if (acl) edg_wll_FreeAcl(acl); - return edg_wll_Error(ctx, NULL, NULL); + edg_wll_SetError(ctx, intErr, errdesc); + free(errdesc); + return edg_wll_UpdateError(ctx, EDG_WLL_ERROR_SERVER_RESPONSE, "Could not compute job status from events"); } if (acl) {