[OpenSIPS-Devel] [ opensips-Patches-3553765 ] create_dialog() - Clear flags before setting new ones
SourceForge.net
noreply at sourceforge.net
Tue Aug 7 23:31:01 CEST 2012
Patches item #3553765, was opened at 2012-08-02 13:44
Message generated for change (Comment added) made by bogdan_iancu
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=1086412&aid=3553765&group_id=232389
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: trunk
>Status: Closed
>Resolution: Fixed
Priority: 5
Private: No
Submitted By: Ryan Bullock (rrb3942)
>Assigned to: Bogdan-Andrei Iancu (bogdan_iancu)
Summary: create_dialog() - Clear flags before setting new ones
Initial Comment:
Currently, if a dialog has already been created, calling create_dialog() with parameters appends the passed flags to the current dialogs flags. This means there is no way to remove a flag after is has been set.
Example:
#Pings callee and sends BYE on timeout
create_dialog("Bp");
#Will still ping callee
create_dialog("B");
#Will now ping caller, callee, and send BYE on timeout
create_dialog("P");
This patch causes create_dialog(), when called with a parameter, to first clear the currently set flags before applying the new flags passed in the function.
Example:
#Pings callee and sends BYE on timeout
create_dialog("Bp");
#No longer pings callee, just sends BYE on timeout
create_dialog("B");
#Just pings caller, does not send BYE on timeout
create_dialog("P");
#Ping caller, callee, and send BYE on timeout
create_dialog("pPB");
#Clears flags, no pings, no BYE on timeout
create_dialog("");
#Makes no changes to flags
create_dialog();
The biggest use case for this is the ability to control pinging the callee when hunting through multiple endpoints that may have varying support for In-Dialog OPTIONS.
Thanks.
----------------------------------------------------------------------
>Comment By: Bogdan-Andrei Iancu (bogdan_iancu)
Date: 2012-08-07 14:31
Message:
Ryan,
I uploaded your patch on trunk and 1.8 - thanks for the patch.
Regards,
Bogdan
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=1086412&aid=3553765&group_id=232389
More information about the Devel
mailing list