Navigation


Changeset 1240:0420ccc4671a in freeDiameter for libfdcore/p_sr.c


Ignore:
Timestamp:
Oct 10, 2013, 11:30:55 PM (11 years ago)
Author:
Sebastien Decugis <sdecugis@freediameter.net>
Branch:
default
Phase:
public
Message:

Add a counter for the sent requests for which we did not wait for an answer. It might be relevant this value contributes to the load estimate of the remote peer, but it is not very reliable

File:
1 edited

Legend:

Unmodified
Added
Removed
  • libfdcore/p_sr.c

    r1239 r1240  
    164164                fd_list_unlink(&first->chain);
    165165                srlist->cnt--;
     166                srlist->cnt_lost++; /* We are not waiting for this answer anymore, but the remote peer may still be processing it. */
    166167                fd_list_unlink(&first->expire);
    167168                free(first);
     
    280281                srl_dump("Current list of SR: ", &srlist->srs);
    281282                *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 */
    282286        } else {
    283287                /* Restore hop-by-hop id */
Note: See TracChangeset for help on using the changeset viewer.