Mark Michelson <mmichel...@digium.com> wrote:

Looking in my Asterisk 11 version of chan_sip.c, in start_session_timer(), the 
first if block looks like this:

    if (p->stimer->st_schedid > -1) {                                           
                        
        /* in the event a timer is already going, stop it */                    
                        
        ast_debug(2, "Session timer stopped: %d - %s\n", p->stimer->st_schedid, 
p->callid);             
        AST_SCHED_DEL_UNREF(sched, p->stimer->st_schedid,                       
                        
            dialog_unref(p, "unref stimer->st_schedid from dialog"));           
                        
    }

So it appears that calling start_session_timer() should be stopping any 
existing timers if they are active. Basically, restart_session_timer() is 
redundant and could be removed.

--------

Thanks.  Now I know what I'm looking for it was fixed in 
https://issues.asterisk.org/jira/browse/ASTERISK-16023 although it makes no 
mention of mis-operation of session timers, and doesn't even mention that if 
fixes leaking internal timers.  The title was "[patch] UDP ports not 
freed/ports leaking".

BTS Holdings PLC - Registered office: BTS House, Manor Road, Wallington, SM6 
0DD - Registered in England: 1517630

-- 
_____________________________________________________________________
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

asterisk-dev mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-dev

Reply via email to