[asterisk-commits] rmudgett: trunk r407325 - in /trunk: ./ res/res_pjsip/pjsip_configuration.c

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Tue Feb 4 12:55:37 CST 2014


Author: rmudgett
Date: Tue Feb  4 12:55:32 2014
New Revision: 407325

URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=407325
Log:
res_pjsip: Fix assertion for pjsip.conf authorization list options.

(closes issue ASTERISK-23168)
Reported by: George Joseph

Review: https://reviewboard.asterisk.org/r/3143/
........

Merged revisions 407324 from http://svn.asterisk.org/svn/asterisk/branches/12

Modified:
    trunk/   (props changed)
    trunk/res/res_pjsip/pjsip_configuration.c

Propchange: trunk/
------------------------------------------------------------------------------
Binary property 'branch-12-merged' - no diff available.

Modified: trunk/res/res_pjsip/pjsip_configuration.c
URL: http://svnview.digium.com/svn/asterisk/trunk/res/res_pjsip/pjsip_configuration.c?view=diff&rev=407325&r1=407324&r2=407325
==============================================================================
--- trunk/res/res_pjsip/pjsip_configuration.c (original)
+++ trunk/res/res_pjsip/pjsip_configuration.c Tue Feb  4 12:55:32 2014
@@ -231,9 +231,13 @@
 	char *val;
 
 	ast_assert(auths != NULL);
-	ast_assert(AST_VECTOR_SIZE(auths) == 0);
-
-	AST_VECTOR_INIT(auths, 1);
+
+	if (AST_VECTOR_SIZE(auths)) {
+		ast_sip_auth_vector_destroy(auths);
+	}
+	if (AST_VECTOR_INIT(auths, 1)) {
+		return -1;
+	}
 
 	while ((val = strsep(&auth_names, ","))) {
 		val = ast_strdup(val);




More information about the asterisk-commits mailing list