[Kamailio-Devel] [ openser-Bugs-2174497 ] dialog module: wrong "lifetime" handling

SourceForge.net noreply at sourceforge.net
Thu Nov 27 15:54:16 CET 2008


Bugs item #2174497, was opened at 2008-10-17 13:01
Message generated for change (Comment added) made by ibc_sf
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=743020&aid=2174497&group_id=139143

Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: modules
Group: ver devel
Status: Open
Resolution: None
Priority: 5
Private: No
Submitted By: Klaus Darilion (klaus_darilion)
Assigned to: Nobody/Anonymous (nobody)
Summary: dialog module: wrong "lifetime" handling

Initial Comment:
In dlg_handlers.c:

function dlg_onroute():

    if ( (event==DLG_EVENT_REQ || event==DLG_EVENT_REQACK)
    && new_state==DLG_STATE_CONFIRMED) {
        LM_DBG("sequential request successfully processed\n");
        timeout = get_dlg_timeout(req);
        /* update timer during sequential request? */
        if (timeout!=default_timeout) {
            dlg->lifetime = timeout;
            if (update_dlg_timer( &dlg->tl, dlg->lifetime )==-1)
                LM_ERR("failed to update dialog lifetime\n");
        }

This causes the timer on in-dialog requests only be updated if the in-dialog request has a differnt timeout than the default module timeout. Thus, if timeout_avp is not used, the timer wont be updated.



----------------------------------------------------------------------

Comment By: Iñaki Baz (ibc_sf)
Date: 2008-11-27 15:54

Message:
Yes, obviously they are two different concepts:

1) Max call duration (current behaviour).
2) Provisional timeout (behaviour with my "patch").

IMHO option 2 makes more sense in most of the cases since the aim of the
administrator is usually check if a dialog still exists.

The existance of both options would be great :)


----------------------------------------------------------------------

Comment By: Nobody/Anonymous (nobody)
Date: 2008-11-27 15:47

Message:
It depends on the policy. Should it be allowed to change the lifetime
during handling of indialog requests or should the lifetime always be
prolonged by the value specified with the intial request?
klaus

----------------------------------------------------------------------

Comment By: Iñaki Baz (ibc_sf)
Date: 2008-11-27 15:21

Message:
I've uncommented the "if" and it seems to work (a sequential request resets
the timer):

		/* update timer during sequential request? */
// 		if (timeout!=default_timeout) {
			dlg->lifetime = timeout;
			if (update_dlg_timer( &dlg->tl, dlg->lifetime )==-1)
				LM_ERR("failed to update dialog lifetime\n");
// 		}

Is it so easy or are there other points to check?

----------------------------------------------------------------------

Comment By: Henning Westerholt (henningw)
Date: 2008-10-17 13:03

Message:
Hi Klaus,

is this perhaps related to this bug:
https://sourceforge.net/tracker/index.php?func=detail&aid=1963639&group_id=139143&atid=743020
?

----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=743020&aid=2174497&group_id=139143



More information about the Devel mailing list