From: Michal Voců Date: Tue, 28 Aug 2012 12:37:53 +0000 (+0000) Subject: instruct IL to not send us faulty messages again X-Git-Tag: glite-lb-common_R_8_2_4_1~6 X-Git-Url: http://scientific.zcu.cz/git/?a=commitdiff_plain;h=e10d1851ed7ba24a92869b15519dfdf22a1e1534;p=jra1mw.git instruct IL to not send us faulty messages again --- diff --git a/org.glite.lb.server/src/request.c b/org.glite.lb.server/src/request.c index a9cf708..769c021 100644 --- a/org.glite.lb.server/src/request.c +++ b/org.glite.lb.server/src/request.c @@ -67,7 +67,7 @@ create_reply(const edg_wll_Context ctx, char **buf) err_code_min = 0; - switch(edg_wll_Error(ctx,NULL,&err_msg)) { + switch(err_code = edg_wll_Error(ctx,NULL,&err_msg)) { case 0: err_code = LB_OK; @@ -86,9 +86,14 @@ create_reply(const edg_wll_Context ctx, char **buf) break; default: - err_code = LB_DBERR; - err_code_min = edg_wll_Error(ctx,NULL,NULL); - break; + if(err_code > EDG_WLL_ERROR_BASE) { + /* that would mean parse error, do not bother sending it again */ + err_code = LB_PROTO; + } else { + err_code = LB_DBERR; + } + err_code_min = edg_wll_Error(ctx,NULL,NULL); + break; }