crm_malloc(fsa_data, sizeof(fsa_data_t));
crm_malloc0(fsa_data, sizeof(fsa_data_t));
send_msg_via_ipc(HA_Message *msg, const char *sys){	gboolean send_ok = TRUE;	IPC_Channel *client_channel;	enum crmd_fsa_input next_input;		crm_trace("relaying msg to sub_sys=%s via IPC", sys);	client_channel =		(IPC_Channel*)g_hash_table_lookup(ipc_clients, sys);	if(cl_get_string(msg, F_CRM_HOST_FROM) == NULL) {		ha_msg_add(msg, F_CRM_HOST_FROM, fsa_our_uname);	}		if (client_channel != NULL) {		crm_devel("Sending message via channel %s.", sys);		send_ok = send_ipc_message(client_channel, msg);		msg = NULL;  /* so the crm_msg_del() below doesnt fail */			} else if(sys != NULL && strcmp(sys, CRM_SYSTEM_CIB) == 0) {		crm_err("Sub-system (%s) has been incorporated into the CRMd.",			sys);		crm_err("Change the way we handle this CIB message");		crm_log_message(LOG_ERR, msg);		send_ok = FALSE;			} else if(sys != NULL && strcmp(sys, CRM_SYSTEM_LRMD) == 0) {		fsa_data_t *fsa_data = NULL;		ha_msg_input_t *msg_copy = new_ha_msg_input(msg);		crm_malloc(fsa_data, sizeof(fsa_data_t));		fsa_data->fsa_input = I_MESSAGE;		fsa_data->fsa_cause = C_IPC_MESSAGE;		fsa_data->data = msg_copy;		fsa_data->origin = __FUNCTION__;		fsa_data->data_type = fsa_dt_ha_msg;		#ifdef FSA_TRACE		crm_verbose("Invoking action %s (%.16llx)",			    fsa_action2string(A_LRM_INVOKE),			    A_LRM_INVOKE);#endif		next_input = do_lrm_invoke(A_LRM_INVOKE, C_IPC_MESSAGE,					   fsa_state, I_MESSAGE, fsa_data);		delete_ha_msg_input(msg_copy);		crm_free(fsa_data);				/* todo: feed this back in for anything != I_NULL */		#ifdef FSA_TRACE		crm_verbose("Result of action %s was %s",			    fsa_action2string(A_LRM_INVOKE),			    fsa_input2string(next_input));#endif			} else {		crm_err("Unknown Sub-system (%s)... discarding message.", sys);		send_ok = FALSE;	}    	crm_msg_del(msg);	return send_ok;}	