[Osip] Subtle bug in eXosip

Vadim Lebedev vadim at mbdsys.com
Tue Feb 12 15:29:14 CET 2008


Hi Aymerc,
Aymeric Moizard wrote:
>
> On Mon, 11 Feb 2008, Vadim Lebedev wrote:
>
>> Hello,
>
> Hi Vadim,
>
>> I've stumbled on a subtle bug in eXosip used in WengoPhone. Of course 
>> it an ancient version but just in case it sneaked in the new version...
>
> I'll keep the remark for the end of the mail ;)
>
>> Due the fact that *eXosip_notify_accept_subscribe* called 
>> *eXosip_notify without *releasing the global mutex, and 
>> *eXosip_execute* handles client transction events before server 
>> transaction events, the NOTIFY request is sent out before 200 OK 
>> responce for the SUBSCRIBE.
>
> Sending the 200ok before the subscribe is COMPLIANT: the 200ok will
> establish/confirm the dialog on the remote application. I see no
> problem here.
>
I was not clear enough.  NOTIFY goes out BEFORE 200 ok


>> My solution was to removed call to *eXosip_notify* from 
>> *eXosip_notify_accept_subscribe *and call it in phAcceptSubscribe 
>> just after call to *eXosip_notify_accept_subscribe *and after 
>> flip-flopping eXosip_lock/unlock
>
> I think the new version don't show this behavior, because it's 
> enterely your choice to send the NOTIFY or SUBSCRIBE's answer in the 
> order you want...
>
> As you expect from me: eXosip2 is much much more flexible than wengo's 
> version ;)
>
I know, i know,
The switch is on the roadmap.... If you want you can help :)


Vadim



More information about the Osip mailing list