fragment = create_cib_fragment(update, NULL);
fragment = create_cib_fragment(update, XML_CIB_TAG_STATUS);
crmd_client_status_callback(const char * node, const char * client,		 const char * status, void * private){	const char    *join = NULL;	const char   *extra = NULL;	crm_data_t *  update = NULL;	crm_debug_3("received callback");	if(safe_str_neq(client, CRM_SYSTEM_CRMD)) {		return;	}	if(safe_str_eq(status, JOINSTATUS)){		status = ONLINESTATUS;/* 		extra  = XML_CIB_ATTR_CLEAR_SHUTDOWN; */	} else if(safe_str_eq(status, LEAVESTATUS)){		status = OFFLINESTATUS;		join   = CRMD_STATE_INACTIVE;		extra  = XML_CIB_ATTR_CLEAR_SHUTDOWN;	}		set_bit_inplace(fsa_input_register, R_PEER_DATA);	g_hash_table_replace(		crmd_peer_state, crm_strdup(node), crm_strdup(status));	if(is_set(fsa_input_register, R_CIB_CONNECTED) == FALSE) {		return;	} else if(fsa_state == S_STOPPING) {		return;	}	crm_notice("Status update: Client %s/%s now has status [%s]",		   node, client, status);	if(safe_str_eq(node, fsa_our_dc)	   && safe_str_eq(status, OFFLINESTATUS)) {		/* did our DC leave us */		crm_info("Got client status callback - our DC is dead");		register_fsa_input(C_CRMD_STATUS_CALLBACK, I_ELECTION, NULL);			} else {		crm_data_t *fragment = NULL;		crm_debug_3("Got client status callback");		update = create_node_state(			node, node, NULL, NULL, status, join, NULL,			__FUNCTION__);				crm_xml_add(update, extra, XML_BOOLEAN_TRUE);		if(safe_str_eq(extra, XML_CIB_ATTR_CLEAR_SHUTDOWN)) {			crm_xml_add(update, XML_CIB_ATTR_REPLACE, XML_TAG_TRANSIENT_NODEATTRS);		}				fragment = create_cib_fragment(update, NULL);		/* it is safe to keep these updates on the local node		 * each node updates their own CIB		 */		fsa_cib_conn->cmds->modify(			fsa_cib_conn, XML_CIB_TAG_STATUS, fragment, NULL,			cib_inhibit_bcast|cib_scope_local|cib_quorum_override);		free_xml(fragment);		free_xml(update);		if(AM_I_DC && safe_str_eq(status, OFFLINESTATUS)) {			g_hash_table_remove(confirmed_nodes,  node);			g_hash_table_remove(finalized_nodes,  node);			g_hash_table_remove(integrated_nodes, node);			g_hash_table_remove(welcomed_nodes,   node);						check_join_state(fsa_state, __FUNCTION__);		}	}		G_main_set_trigger(fsa_source);}