Changeset 1240:0420ccc4671a in freeDiameter
- Timestamp:
- Oct 10, 2013, 11:30:55 PM (11 years ago)
- Branch:
- default
- Phase:
- public
- Location:
- libfdcore
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
libfdcore/fdcore-internal.h
r1238 r1240 130 130 struct fd_list exp; /* requests that have a timeout set, ordered by timeout */ 131 131 long cnt; /* number of requests in the srs list */ 132 long cnt_lost; /* number of requests that have not been answered in time. 133 It is decremented when an unexpected answer is received, so this may not be accurate. */ 132 134 pthread_mutex_t mtx; /* mutex to protect these lists */ 133 135 pthread_cond_t cnd; /* cond var used by the thread that handles timeouts */ -
libfdcore/p_sr.c
r1239 r1240 164 164 fd_list_unlink(&first->chain); 165 165 srlist->cnt--; 166 srlist->cnt_lost++; /* We are not waiting for this answer anymore, but the remote peer may still be processing it. */ 166 167 fd_list_unlink(&first->expire); 167 168 free(first); … … 280 281 srl_dump("Current list of SR: ", &srlist->srs); 281 282 *req = NULL; 283 if (srlist->cnt_lost > 0) { 284 srlist->cnt_lost--; /* This is probably an answer for a request we already timedout. */ 285 } /* else, probably a bug in the remote peer */ 282 286 } else { 283 287 /* Restore hop-by-hop id */
Note: See TracChangeset
for help on using the changeset viewer.