else if (strcmp(CRM_SYSTEM_CIB, curr_client->sub_sys) == 0) have_cib = FALSE;
crmd_ipc_input_callback(IPC_Channel *client, gpointer user_data){	int lpc = 0;	char *buffer = NULL;	IPC_Message *msg = NULL;	gboolean hack_return_good = TRUE;	crmd_client_t *curr_client = (crmd_client_t*)user_data;	FNIN();	CRM_DEBUG2("processing IPC message from %s",		   curr_client->table_key);	while(client->ops->is_message_pending(client)) {		if (client->ch_status == IPC_DISCONNECT) {			/* The message which was pending for us is that			 * the IPC status is now IPC_DISCONNECT */			break;		}		if (client->ops->recv(client, &msg) != IPC_OK) {			perror("Receive failure:");			FNRET(!hack_return_good);		}		if (msg == NULL) {			CRM_DEBUG("No message this time");			continue;		}		lpc++;		buffer = (char*)msg->msg_body;		CRM_DEBUG2("Got xml [text=%s]", buffer);			xmlNodePtr root_xml_node =			find_xml_in_ipcmessage(msg, FALSE);		if (root_xml_node != NULL) {			if (crmd_authorize_message(root_xml_node,						   msg,						   curr_client)) {				CRM_DEBUG("Message authorized, about to relay");				process_message(root_xml_node, TRUE, NULL);			} else				CRM_DEBUG("Message not authorized");		} else {			cl_log(LOG_INFO,			       "IPC Message was not valid... discarding message.");		}		free_xml(root_xml_node);		msg->msg_done(msg);	}	CRM_DEBUG2("Processed %d messages", lpc);    	if (client->ch_status == IPC_DISCONNECT)	{		cl_log(LOG_INFO,		       "received HUP from %s",		       curr_client->table_key);		if (curr_client != NULL) {						if (curr_client->sub_sys == NULL)				CRM_DEBUG("Client had not registered with us yet");			else if (strcmp(CRM_SYSTEM_LRMD,					curr_client->sub_sys) == 0)				have_lrmd = FALSE;			else if (strcmp(CRM_SYSTEM_PENGINE,					curr_client->sub_sys) == 0)				have_te = FALSE;			else if (strcmp(CRM_SYSTEM_TENGINE,					curr_client->sub_sys) == 0)				have_pe = FALSE;			if (curr_client->table_key != NULL) {				/*				 * Key is destroyed below: curr_client->table_key				 * Value is cleaned up by G_main_del_IPC_Channel				 */				g_hash_table_remove(					ipc_clients,					curr_client->table_key);			}			if(curr_client->client_source != NULL) {				gboolean det =					G_main_del_IPC_Channel(curr_client->client_source);							CRM_DEBUG2("crm_client was %s detached",					   det?"successfully":"not");			}						ha_free(curr_client->table_key);			ha_free(curr_client->sub_sys);			ha_free(curr_client->uid);			ha_free(curr_client);		}		CRM_DEBUG("this client has now left the building.");		FNRET(!hack_return_good);	}    	FNRET(hack_return_good);}