summaryrefslogtreecommitdiff
path: root/include/asterisk/res_pjsip.h
diff options
context:
space:
mode:
authorCorey Farrell <git@cfware.com>2017-10-04 11:59:49 -0400
committerCorey Farrell <git@cfware.com>2017-10-04 12:00:47 -0400
commit65399a5edac34b4b2b9982fc0ad82489350b57d2 (patch)
tree293a3793f84f0bd1ecd176abaf858892ed7cc83e /include/asterisk/res_pjsip.h
parent7d04544986980aed9eca9e13d6b849ff3b372f35 (diff)
res_pjsip: Add REF_DEBUG info to module references.
This provides better information to REF_DEBUG log for troubleshooting when the system is unable to unload res_pjsip.so during shutdown due to module references. ASTERISK-27306 Change-Id: I63197ad33d1aebe60d12e0a6561718bdc54e4612
Diffstat (limited to 'include/asterisk/res_pjsip.h')
-rw-r--r--include/asterisk/res_pjsip.h18
1 files changed, 14 insertions, 4 deletions
diff --git a/include/asterisk/res_pjsip.h b/include/asterisk/res_pjsip.h
index b6403d6fa..e6ccf0a1d 100644
--- a/include/asterisk/res_pjsip.h
+++ b/include/asterisk/res_pjsip.h
@@ -925,7 +925,9 @@ enum ast_sip_contact_filter {
* \retval 0 Success
* \retval -1 Failure
*/
-int ast_sip_register_service(pjsip_module *module);
+#define ast_sip_register_service(module) \
+ __ast_sip_register_service(module, __FILE__, __LINE__, __PRETTY_FUNCTION__)
+int __ast_sip_register_service(pjsip_module *module, const char *file, int line, const char *func);
/*!
* This is the opposite of ast_sip_register_service(). Unregistering a
@@ -934,7 +936,9 @@ int ast_sip_register_service(pjsip_module *module);
*
* \param module The PJSIP module to unregister
*/
-void ast_sip_unregister_service(pjsip_module *module);
+#define ast_sip_unregister_service(module) \
+ __ast_sip_unregister_service(module, __FILE__, __LINE__, __PRETTY_FUNCTION__)
+void __ast_sip_unregister_service(pjsip_module *module, const char *file, int line, const char *func);
/*!
* \brief Register a SIP authenticator
@@ -2615,14 +2619,20 @@ struct ast_sip_supplement {
* \retval 0 Success
* \retval -1 Failure
*/
-int ast_sip_register_supplement(struct ast_sip_supplement *supplement);
+#define ast_sip_register_supplement(supplement) \
+ __ast_sip_register_supplement(supplement, __FILE__, __LINE__, __PRETTY_FUNCTION__)
+int __ast_sip_register_supplement(struct ast_sip_supplement *supplement,
+ const char *file, int line, const char *func);
/*!
* \brief Unregister a an supplement to SIP out of dialog processing
*
* \param supplement The supplement to unregister
*/
-void ast_sip_unregister_supplement(struct ast_sip_supplement *supplement);
+#define ast_sip_unregister_supplement(supplement) \
+ __ast_sip_unregister_supplement(supplement, __FILE__, __LINE__, __PRETTY_FUNCTION__)
+void __ast_sip_unregister_supplement(struct ast_sip_supplement *supplement,
+ const char *file, int line, const char *func);
/*!
* \brief Retrieve the global MWI taskprocessor high water alert trigger level.