[asterisk-commits] mmichelson: branch group/CCSS_Monitor_Restructure r242035 - /team/group/CCSS_...

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Thu Jan 21 13:26:58 CST 2010


Author: mmichelson
Date: Thu Jan 21 13:26:54 2010
New Revision: 242035

URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=242035
Log:
Remove init callbacks since they are unnecessary.


Modified:
    team/group/CCSS_Monitor_Restructure/main/ccss.c

Modified: team/group/CCSS_Monitor_Restructure/main/ccss.c
URL: http://svnview.digium.com/svn/asterisk/team/group/CCSS_Monitor_Restructure/main/ccss.c?view=diff&rev=242035&r1=242034&r2=242035
==============================================================================
--- team/group/CCSS_Monitor_Restructure/main/ccss.c (original)
+++ team/group/CCSS_Monitor_Restructure/main/ccss.c Thu Jan 21 13:26:54 2010
@@ -901,21 +901,14 @@
 	AST_DLLIST_ENTRY(cc_monitor) next;
 };
 
-static int cc_butt_extension_monitor_init(struct ast_cc_monitor *monitor, const int core_id);
 static int cc_extension_monitor_status_response(struct ast_cc_monitor *monitor, const int core_id, enum ast_device_state devstate);
 static int cc_extension_monitor_unsuspend(struct ast_cc_monitor *monitor, const int core_id);
 
 static struct ast_cc_monitor_callbacks extension_monitor_cbs = {
 	.type = "extension",
-	.init = cc_butt_extension_monitor_init,
 	.status_response = cc_extension_monitor_status_response,
 	.unsuspend = cc_extension_monitor_unsuspend,
 };
-
-static int cc_butt_extension_monitor_init(struct ast_cc_monitor *monitor, const int core_id)
-{
-	return 0;
-}
 
 static int cc_extension_monitor_status_response(struct ast_cc_monitor *monitor, const int core_id, enum ast_device_state devstate)
 {
@@ -949,7 +942,6 @@
 	return 0;
 }
 
-static int cc_generic_monitor_init(struct ast_cc_monitor *monitor, const int core_id);
 static int cc_generic_monitor_request_cc2(struct cc_monitor *monitor, int *available_timer_id);
 static int cc_generic_monitor_suspend2(struct cc_monitor *monitor);
 static int cc_generic_monitor_status_response(struct ast_cc_monitor *monitor, const int core_id, enum ast_device_state devstate);
@@ -959,7 +951,6 @@
 
 static struct ast_cc_monitor_callbacks generic_monitor_cbs = {
 	.type = "generic",
-	.init = cc_generic_monitor_init,
 	.request_cc2 = cc_generic_monitor_request_cc2,
 	.suspend2 = cc_generic_monitor_suspend2,
 	.status_response = cc_generic_monitor_status_response,
@@ -1072,18 +1063,6 @@
 	generic_list->current_state = ast_device_state(monitor->interface->name);
 	ao2_link(generic_monitors, generic_list);
 	return generic_list;
-}
-
-static int cc_generic_monitor_init(struct ast_cc_monitor *monitor, const int core_id)
-{
-	struct generic_monitor_pvt *gen_mon_pvt = ast_calloc(1, sizeof(*gen_mon_pvt));
-
-	if (!gen_mon_pvt) {
-		return -1;
-	}
-	ast_log_dynamic_level(cc_logger_level, "Allocated a generic monitor pvt for device %s\n", monitor->interface->name);
-	monitor->private_data = gen_mon_pvt;
-	return 0;
 }
 
 struct generic_tp_cb_data {




More information about the asterisk-commits mailing list