[svn-commits] mmichelson: branch 12 r410011 - /branches/12/res/res_pjsip_mwi.c

SVN commits to the Digium repositories svn-commits at lists.digium.com
Thu Mar 6 09:43:49 CST 2014


Author: mmichelson
Date: Thu Mar  6 09:43:43 2014
New Revision: 410011

URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=410011
Log:
Don't attempt to link in an aggregate MWI subscription if an endpoint does not aggregate MWI.

Attempting to link a NULL object into an ao2 container had been benign previously, but since
enabling DO_CRASH in the testsuite, this is now causing a crash. It's better to be right
here anyway.


Modified:
    branches/12/res/res_pjsip_mwi.c

Modified: branches/12/res/res_pjsip_mwi.c
URL: http://svnview.digium.com/svn/asterisk/branches/12/res/res_pjsip_mwi.c?view=diff&rev=410011&r1=410010&r2=410011
==============================================================================
--- branches/12/res/res_pjsip_mwi.c (original)
+++ branches/12/res/res_pjsip_mwi.c Thu Mar  6 09:43:43 2014
@@ -755,7 +755,9 @@
 			ao2_cleanup(sub);
 		}
 	}
-	ao2_link(mwi_subscriptions, aggregate_sub);
+	if (aggregate_sub) {
+		ao2_link(mwi_subscriptions, aggregate_sub);
+	}
 	return 0;
 }
 




More information about the svn-commits mailing list