Hi Andrei,
thank you for looking at the problem.
You mean t_uac_prepare() (called via
tmb->t_request, request(),
t_uac(), t_uac_with_ids(), t_uac_prepare()) ?
Yes, that's it.
Rather then adding a parameter for not reseting the
avp list to
build_cell() and commenting it out in t_request(), I think the solution
is not copying the avp lists at all for the local transaction (so a
parameter for creating a transaction with an empty avp list).
I already tried to change the build_cell() function in this way.
When
new_cell->uri_avps_from
new_cell->uri_avps_to
new_cell->user_avps_from
new_cell->user_avps_to
are zero-pointers, kamailio dies a few seconds after sending out the
PUBLISH request.
Which changes would you recommend to create an empty avp list?
Thank you very much.
Best Regards
Jasmin
Am Mittwoch, den 11.08.2010, 15:14 +0200 schrieb Andrei
Pelinescu-Onciul:
> On Aug 11, 2010 at 05:45, Jasmin Schnatterbeck <js(a)data-cmr.net> wrote:
> > Hello List,
> >
> > some months ago I reported a problem with pua_dialoginfo:
> > Avps declared in request route are not available anymore in branch
> > route, if pua_dialoginfo module is loaded.
> >
> > I do not know whether there are some experiences with this problem or
> > not, so I looked for the reason.
> >
> > pua_dialoginfo uses pua for sending PUBLISH request
> > pua uses tm t_request for sending PUBLISH request
> >
> > t_request() is located in uac.c (tm):
>
You mean t_uac_prepare() (called via
tmb->t_request, request(),
t_uac(), t_uac_with_ids(), t_uac_prepare()) ?
> > - in line 411 avp list is reset
> > - in line 276 build_cell() is called:
> > build_cell() is located in h_table.c, where lines 305-323 delete avps
> >
> > If I comment out the mentioned lines, which delete avps, then avps set
> > in request route are also available in branch route.
> > But I do not know, what is also affected by this change.
> >
> > So would it be reasonable, to add a parameter to build_cell() for not
> > changing the AVP list?
>
> The problem is that the AVP lists cannot be shared between several
> transactions and in your case there are probably 2 transactions that
> would share them without the reset: the transaction created by
> t_relay()/t_newtran() and the local PUBLISH transaction created by
> pua_dialoginfo.
Rather then adding a parameter for not reseting the
avp list to
build_cell() and commenting it out in t_request(), I think the solution
is not copying the avp lists at all for the local transaction (so a
parameter for creating a transaction with an empty avp list).
> Another
possibility would to clone the avp list instead of linking to
> it in the t_uac_prepare() case, but this would be expensive and I don't
> think anybody needs a local transaction that would inherit the avps
> (there is only an event route executed on the local transaction creation
> an that can access the original avps anyway).
>
> Andrei