On Wed May 15 22:41:44 EDT 2013 onmyway133 at gmail dot com said " @saltyfoam You can check for current_op in pjsip_regc They can be in IDLE, REGISTERING, UNREGISTERING " My attempts to access and test current_op fail. I have read online documentation and source code for a few days. Here is where I am stopped: #include <pjsip-ua/sip_regc.h> void cb_on_reg_state2 (pjsua_acc_id acc_id, pjsua_reg_info *info) { PJ_LOG(3,(__FILE__, "%s: Account %d Reason %.*s Status %d CurrentOp %d", __FUNCTION__, acc_id, info->cbparam->reason.slen, info->cbparam->reason.ptr, info->cbparam->status, info->cbparam->regc->current_op )); } error: invalid use of incomplete type 'pjsip_regc {aka struct pjsip_regc}' __FUNCTION__, acc_id, info->cbparam->reason.slen, info->cbparam->reason.ptr, info->cbparam->status, info->cbparam->regc->current_op )); The compiler declares struct pjsip_regc to be an incomplete type. /usr/include/pjsip-ua/sip_regc.h only gives a typedef struct pjsip_regc pjsip_regc; the structure definition is only in pjsip/src/pjsip-ua/sip_reg.c So, how do I inform the compiler where to get current_op? The brute-force method looks to be moving the pjsip_regc structure declaration into the header file ahead of the typedef, and removing it from the source file. Clues begged piteously. ---------------------------------------------------------------------------------------------------------------------------- Confidentiality Requirement: This communication, including any attachment(s), may contain confidential information and is for the sole use of the intended recipient(s). If you are not the intended recipient, you are hereby notified that you have received this communication in error and any unauthorized review, use, disclosure, dissemination, distribution or copying of it or its contents is strictly prohibited. If you have received this communication in error, please notify the sender immediately by telephone or e-mail and destroy all copies of this communication and any attachments. -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.pjsip.org/pipermail/pjsip_lists.pjsip.org/attachments/20150121/feeef179/attachment.html>