Mercurial > hg > freeDiameter
changeset 198:5ea550c3f033
Fix handling of long network failures
author | Sebastien Decugis <sdecugis@nict.go.jp> |
---|---|
date | Tue, 09 Feb 2010 17:59:15 +0900 |
parents | 6a033f90d8ea |
children | 3e79fef1031d |
files | freeDiameter/cnxctx.c freeDiameter/p_psm.c |
diffstat | 2 files changed, 7 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/freeDiameter/cnxctx.c Mon Feb 08 18:35:51 2010 +0900 +++ b/freeDiameter/cnxctx.c Tue Feb 09 17:59:15 2010 +0900 @@ -680,6 +680,9 @@ case GNUTLS_E_INTERRUPTED: if (!conn->cc_closing) goto again; + TRACE_DEBUG(INFO, "Connection is closing, so abord gnutls_record_recv now."); + ret = 0; + break; default: TRACE_DEBUG(INFO, "This TLS error is not handled, assume unrecoverable error");
--- a/freeDiameter/p_psm.c Mon Feb 08 18:35:51 2010 +0900 +++ b/freeDiameter/p_psm.c Tue Feb 09 17:59:15 2010 +0900 @@ -665,8 +665,11 @@ CHECK_FCT_DO( fd_p_cnx_init(peer), goto psm_end ); goto psm_loop; + case STATE_SUSPECT: + /* Mark the connection problem */ + peer->p_flags.pf_cnx_pb = 1; + case STATE_CLOSING: - case STATE_SUSPECT: case STATE_WAITCNXACK: case STATE_WAITCEA: /* Destroy the connection, restart the timer to a new connection attempt */