@saltyfoam You can check for current_op in pjsip_regc They can be in IDLE, REGISTERING, UNREGISTERING On Fri, May 10, 2013 at 11:31 AM, <saltyfoam at gmail.com> wrote: > I am writing the softphone. The on_reg_state2 callback is definitely being > called for both register and unregister. > > *From: *Khoa Pham > *Sent: *Thursday, May 9, 2013 8:31 PM > *To: *pjsip list > *Reply To: *pjsip list > *Subject: *Re: In the registration callback, how to tell if > registering > > or unregistering? > > @Dominique, > > What is your pjsip softphone ? It depends on that sofphone 's behavior > AFAIK, on_reg_state is only for register, not for unregister > > > On Fri, May 10, 2013 at 4:43 AM, <saltyfoam at gmail.com> wrote: > >> Hi, >> >> If the registration callback (pjsua_config.cb.on_reg_state2) is called >> with a failure, how to tell if the failure was for an unregister attempt or >> a register attempt? When I make a change to an account it?s going to >> trigger an unregister followed by a reregister but I don?t see how I can >> tell what stage the failure is for. >> >> Dominique >> >> _______________________________________________ >> Visit our blog: http://blog.pjsip.org >> >> pjsip mailing list >> pjsip at lists.pjsip.org >> http://lists.pjsip.org/mailman/listinfo/pjsip_lists.pjsip.org >> >> > > > -- > Khoa Pham > HCMC University of Science > Faculty of Information Technology > > > _______________________________________________ > Visit our blog: http://blog.pjsip.org > > pjsip mailing list > pjsip at lists.pjsip.org > http://lists.pjsip.org/mailman/listinfo/pjsip_lists.pjsip.org > > _______________________________________________ > Visit our blog: http://blog.pjsip.org > > pjsip mailing list > pjsip at lists.pjsip.org > http://lists.pjsip.org/mailman/listinfo/pjsip_lists.pjsip.org > > -- Khoa Pham HCMC University of Science Faculty of Information Technology -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.pjsip.org/pipermail/pjsip_lists.pjsip.org/attachments/20130516/64f94d8a/attachment-0001.html>