[asterisk-commits] file: trunk r410845 - in /trunk: ./ res/res_pjsip/config_system.c
SVN commits to the Asterisk project
asterisk-commits at lists.digium.com
Tue Mar 18 07:45:53 CDT 2014
Author: file
Date: Tue Mar 18 07:45:49 2014
New Revision: 410845
URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=410845
Log:
res_pjsip: Fix memory leak of nameservers in off-nominal resolver creation failure.
Thanks Walter Doekes!
........
Merged revisions 410844 from http://svn.asterisk.org/svn/asterisk/branches/12
Modified:
trunk/ (props changed)
trunk/res/res_pjsip/config_system.c
Propchange: trunk/
------------------------------------------------------------------------------
Binary property 'branch-12-merged' - no diff available.
Modified: trunk/res/res_pjsip/config_system.c
URL: http://svnview.digium.com/svn/asterisk/trunk/res/res_pjsip/config_system.c?view=diff&rev=410845&r1=410844&r2=410845
==============================================================================
--- trunk/res/res_pjsip/config_system.c (original)
+++ trunk/res/res_pjsip/config_system.c Tue Mar 18 07:45:49 2014
@@ -201,6 +201,7 @@
status = pjsip_endpt_create_resolver(ast_sip_get_pjsip_endpoint(), &resolver);
if (status != PJ_SUCCESS) {
ast_log(LOG_ERROR, "Could not create DNS resolver(%d), resorting to system resolution\n", status);
+ ao2_ref(discovered_nameservers, -1);
return 0;
}
}
@@ -241,4 +242,4 @@
void ast_sip_initialize_dns(void)
{
ast_sip_push_task_synchronous(NULL, system_create_resolver_and_set_nameservers, NULL);
-}
+}
More information about the asterisk-commits
mailing list