[OpenSIPS-Users] [dialog] Can't fetch data in 200 reply route of BYE

Bogdan-Andrei Iancu bogdan at voice-system.ro
Wed Mar 10 17:13:51 CET 2010


Hi,

I guess what you are describing is the same as this bug report:
    
https://sourceforge.net/tracker/?func=detail&aid=2941492&group_id=232389&atid=1086410

Am I right ?

Regards,
Bogdan

liuf wrote:
> I'm sorry. My real question is about where to set dialog pointer to the new
> transaction of sequential request, so that opensips can retrieve the correct
> dialog pointer in the correspond reply.
>
> My actions as below, please help me check:
>
> 1. I used fetch_dlg_value function in onreply_route, when opensips received
> 100/200 reply of INVITE, I can get dialog stored value, but in 200 reply of
> BYE, I can't get any data.
>
> 2. First, I found opensips had not get dialog pointer in w_fetch_dlg_value
> function.
>
> 3. In get_current_dialog function, if 200 reply, ONREPLY_ROUTE,
> trans->dialog_ctx will be return.
>
> 4. I found dialog_ctx seem only can be set in function dlg_onreq when
> opensips received BYE.
>
> 5. According my addtion debug info, I found when opensips received BYE,
> dlg_onreq will be exec.
>
> 6. I guess when opensips received sequential request (BYE), it will create
> new transaction, then set current dialog pointer to this new transaction in
> dlg_onreq function. Then when reply of these requests (200) be received,
> current dialog pointer can be get via get_current_dialog function.
>
> 7. So I consider in function dlg_onreq, move t->dialog_ctx =
> (void*)current_dlg_pointer; to the position that before "if (
> current_dlg_pointer->flags & DLG_FLAG_ISINIT )".
>
> ===========================================================
> void dlg_onreq(struct cell* t, int type, struct tmcb_params *param)
> {
>         /* is the dialog already created? */
>         if (current_dlg_pointer!=NULL) {
>
>                 t->dialog_ctx = (void*)current_dlg_pointer;
>
>                 /* new, un-initialized dialog ? */
>                 if ( current_dlg_pointer->flags & DLG_FLAG_ISINIT )
>                         return;
>
>                 /* dialog was previously created by create_dialog()
>                    -> just do the last settings */
>                 run_create_callbacks( current_dlg_pointer, param->req);
> ..........
> =========================================================== 
>   


-- 
Bogdan-Andrei Iancu
www.voice-system.ro




More information about the Users mailing list