crm_info("Registered %s on %s channel", cib_client->id, cib_client->channel_name);
crm_debug("Registered %s on %s channel", cib_client->id, cib_client->channel_name);
cib_null_callback(IPC_Channel *channel, gpointer user_data){	gboolean did_disconnect = TRUE;	HA_Message *op_request = NULL;	cib_client_t *cib_client = user_data;	cib_client_t *hash_client = NULL;	const char *type = NULL;	const char *uuid_ticket = NULL;	const char *client_name = NULL;	gboolean register_failed = FALSE;	if(cib_client == NULL) {		crm_err("Discarding IPC message from unknown source"			" on callback channel.");		return FALSE;	}		while(channel->ops->is_message_pending(channel)) {		if (channel->ch_status != IPC_CONNECT) {			/* The message which was pending for us is that			 * the channel is no longer fully connected.			 *			 * Dont read requests from disconnected clients			 */			break;		}		op_request = msgfromIPC_noauth(channel);		type = cl_get_string(op_request, F_CIB_OPERATION);		if(safe_str_eq(type, T_CIB_NOTIFY) ) {			/* Update the notify filters for this client */			int on_off = 0;			ha_msg_value_int(				op_request, F_CIB_NOTIFY_ACTIVATE, &on_off);			type = cl_get_string(op_request, F_CIB_NOTIFY_TYPE);			if(safe_str_eq(type, T_CIB_POST_NOTIFY)) {				cib_client->post_notify = on_off;							} else if(safe_str_eq(type, T_CIB_PRE_NOTIFY)) {				cib_client->pre_notify = on_off;			} else if(safe_str_eq(type, T_CIB_UPDATE_CONFIRM)) {				cib_client->confirmations = on_off;			}			continue;					} else if(safe_str_neq(type, CRM_OP_REGISTER) ) {			crm_warn("Discarding IPC message from %s on callback channel",				 cib_client->id);			crm_msg_del(op_request);			continue;		}		uuid_ticket = cl_get_string(op_request, F_CIB_CALLBACK_TOKEN);		client_name = cl_get_string(op_request, F_CIB_CLIENTNAME);		CRM_DEV_ASSERT(uuid_ticket != NULL);		if(crm_assert_failed) {			register_failed = crm_assert_failed;		}				CRM_DEV_ASSERT(client_name != NULL);		if(crm_assert_failed) {			register_failed = crm_assert_failed;		}		if(register_failed == FALSE) {			hash_client = g_hash_table_lookup(client_list, uuid_ticket);			if(hash_client != NULL) {				crm_err("Duplicate registration request..."					" disconnecting");				register_failed = TRUE;			}		}				if(register_failed) {			crm_err("Registration request failed... disconnecting");			crm_msg_del(op_request);			return FALSE;		}		cib_client->id   = crm_strdup(uuid_ticket);		cib_client->name = crm_strdup(client_name);		g_hash_table_insert(client_list, cib_client->id, cib_client);		crm_info("Registered %s on %s channel",			    cib_client->id, cib_client->channel_name);		crm_msg_del(op_request);		op_request = ha_msg_new(2);		ha_msg_add(op_request, F_CIB_OPERATION, CRM_OP_REGISTER);		ha_msg_add(op_request, F_CIB_CLIENTID,  cib_client->id);				send_ipc_message(channel, op_request);	}	did_disconnect = cib_process_disconnect(channel, cib_client);		if(did_disconnect) {		crm_info("Client disconnected");	}		return did_disconnect;}