From: Zdeněk Salvet Date: Thu, 11 May 2006 17:12:16 +0000 (+0000) Subject: Handle ECONNRESET on input, enable reconnection. Fixes bug #9777. X-Git-Tag: glite-lb-common_R_3_1_2~1 X-Git-Url: http://scientific.zcu.cz/git/?a=commitdiff_plain;h=4e4e18c4eae907146d40c5c86a695659260c7820;p=jra1mw.git Handle ECONNRESET on input, enable reconnection. Fixes bug #9777. --- diff --git a/org.glite.lb.common/src/lb_plain_io.c b/org.glite.lb.common/src/lb_plain_io.c index a1e4dd2..1de8e37 100644 --- a/org.glite.lb.common/src/lb_plain_io.c +++ b/org.glite.lb.common/src/lb_plain_io.c @@ -135,6 +135,7 @@ cleanup: if ( to->tv_sec < 0 ) to->tv_sec = to->tv_usec = 0; } + if ( errno == ECONNRESET) errno = ENOTCONN; if ( errno ) return -1; if ( conn->bufUse > 0 ) { diff --git a/org.glite.lb.common/src/mini_http.c b/org.glite.lb.common/src/mini_http.c index fcb3157..0535aa6 100644 --- a/org.glite.lb.common/src/mini_http.c +++ b/org.glite.lb.common/src/mini_http.c @@ -55,6 +55,7 @@ edg_wll_ErrorCode edg_wll_http_recv(edg_wll_Context ctx,char **firstOut,char *** edg_wll_SetErrorGss(ctx, "receving HTTP request", &gss_code); goto error; case EDG_WLL_GSS_ERROR_ERRNO: + if (errno == ECONNRESET) errno = ENOTCONN; edg_wll_SetError(ctx,errno,"edg_wll_gss_read()"); goto error; case EDG_WLL_GSS_ERROR_TIMEOUT: