[asterisk-commits] kmoore: branch kmoore/stasis-mwi r382505 - in /team/kmoore/stasis-mwi: ./ main/

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Wed Mar 6 10:38:14 CST 2013


Author: kmoore
Date: Wed Mar  6 10:38:11 2013
New Revision: 382505

URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=382505
Log:
Forgot to cleanup update->type
........

Merged revisions 382503 from http://svn.asterisk.org/svn/asterisk/team/dlee/stasis-core

Modified:
    team/kmoore/stasis-mwi/   (props changed)
    team/kmoore/stasis-mwi/main/stasis_cache.c

Propchange: team/kmoore/stasis-mwi/
------------------------------------------------------------------------------
--- svnmerge-integrated (original)
+++ svnmerge-integrated Wed Mar  6 10:38:11 2013
@@ -1,1 +1,1 @@
-/team/dlee/stasis-core:1-382491
+/team/dlee/stasis-core:1-382504

Modified: team/kmoore/stasis-mwi/main/stasis_cache.c
URL: http://svnview.digium.com/svn/asterisk/team/kmoore/stasis-mwi/main/stasis_cache.c?view=diff&rev=382505&r1=382504&r2=382505
==============================================================================
--- team/kmoore/stasis-mwi/main/stasis_cache.c (original)
+++ team/kmoore/stasis-mwi/main/stasis_cache.c Wed Mar  6 10:38:11 2013
@@ -308,6 +308,8 @@
 	update->old_snapshot = NULL;
 	ao2_cleanup(update->new_snapshot);
 	update->new_snapshot = NULL;
+	ao2_cleanup(update->type);
+	update->type = NULL;
 }
 
 static struct stasis_message *update_create(struct stasis_topic *topic, struct stasis_message *old_snapshot, struct stasis_message *new_snapshot)
@@ -316,6 +318,7 @@
 	RAII_VAR(struct stasis_message *, msg, NULL, ao2_cleanup);
 
 	ast_assert(topic != NULL);
+	ast_assert(old_snapshot != NULL || new_snapshot != NULL);
 
 	update = ao2_alloc(sizeof(*update), stasis_cache_update_dtor);
 	if (!update) {
@@ -465,13 +468,11 @@
 
 	__cache_update = stasis_message_type_create("stasis_cache_update");
 	if (!__cache_update) {
-		ast_log(LOG_ERROR, "Stasis threadpool allocation failed\n");
 		return -1;
 	}
 
 	__cache_clear_data = stasis_message_type_create("StasisCacheClear");
 	if (!__cache_clear_data) {
-		ast_log(LOG_ERROR, "Failed to initialize Stasis cache\n");
 		return -1;
 	}
 	return 0;




More information about the asterisk-commits mailing list