[pjsip] NOTIFY with status=terminated handling

Benny Prijono bennylp at teluu.com
Wed Aug 19 09:08:48 EDT 2009

On Wed, Aug 19, 2009 at 1:19 PM, Klaus
Darilion<klaus.mailinglists at pernau.at> wrote:
>> This is handled by PJSUA-LIB, it will refresh buddy subscriptions
>> every PJSUA_PRES_TIMER (default 300 seconds).
> Is there a callback so that application will know when the server terminated
> the subscription?

*I think* on_buddy_state() should be called every time NOTIFY is
received, regardless of whether subscription state is terminated or
not in the NOTIFY (remember that SIP Event allows sending initial
SUBSCRIBE with Expires=0 to get the status without establishing a
session, we support this as well).

Previously, NOTIFY without body will not trigger the callback since it
doesn't change presence state, but this was changed in 1.3 (see #873).
So on_body_state() is now called on every NOTIFY.


More information about the pjsip mailing list