crm_data_t *local_cib = get_cib_copy(fsa_cib_conn); crm_data_t *root      = get_object_root(XML_CIB_TAG_STATUS, local_cib); crm_data_t *resources = NULL; const char *rsc_id    = NULL; const char *node_id   = NULL; const char *rsc_state = NULL; const char *op_status = NULL; const char *last_rc   = NULL; const char *last_op   = NULL;   const char *path[] = { XML_CIB_TAG_LRM, XML_LRM_TAG_RESOURCES };  xml_child_iter( root, node, XML_CIB_TAG_STATE,  resources = find_xml_node_nested(node, path, DIMOF(path));  xml_child_iter( resources, rsc, XML_LRM_TAG_RESOURCE,  rsc_id    = crm_element_value(rsc, XML_ATTR_ID); node_id   = crm_element_value(rsc, XML_LRM_ATTR_TARGET); rsc_state = crm_element_value(rsc, XML_LRM_ATTR_RSCSTATE); op_status = crm_element_value(rsc, XML_LRM_ATTR_OPSTATUS); last_rc   = crm_element_value(rsc, XML_LRM_ATTR_RC); last_op   = crm_element_value(rsc, XML_LRM_ATTR_LASTOP);  /* 			if(safe_str_eq(rsc_state, "stopped")) { */ /* 				continue; */ /* 			} */  if(safe_str_neq(op_status, "-1")) { crm_info("Resource state: %s %s " "[%s (rc=%s) after %s] on %s", rsc_id, rsc_state, op_status, last_rc, last_op, node_id); } else { crm_warn("Resource state: %s %s " "[pending %s] on %s", rsc_id, rsc_state, last_op, node_id); }  ); ); 
int call_id = fsa_cib_conn->cmds->query( fsa_cib_conn, NULL, NULL, cib_scope_local); add_cib_op_callback(call_id, TRUE, NULL, dump_rsc_info_callback); 
dump_rsc_info(void){	crm_data_t *local_cib = get_cib_copy(fsa_cib_conn);	crm_data_t *root      = get_object_root(XML_CIB_TAG_STATUS, local_cib);	crm_data_t *resources = NULL;	const char *rsc_id    = NULL;	const char *node_id   = NULL;	const char *rsc_state = NULL;	const char *op_status = NULL;	const char *last_rc   = NULL;	const char *last_op   = NULL;		const char *path[] = {		XML_CIB_TAG_LRM,		XML_LRM_TAG_RESOURCES	};	xml_child_iter(		root, node, XML_CIB_TAG_STATE,				resources = find_xml_node_nested(node, path, DIMOF(path));		xml_child_iter(			resources, rsc, XML_LRM_TAG_RESOURCE,			rsc_id    = crm_element_value(rsc, XML_ATTR_ID);			node_id   = crm_element_value(rsc, XML_LRM_ATTR_TARGET);			rsc_state = crm_element_value(rsc, XML_LRM_ATTR_RSCSTATE);			op_status = crm_element_value(rsc, XML_LRM_ATTR_OPSTATUS);			last_rc   = crm_element_value(rsc, XML_LRM_ATTR_RC);			last_op   = crm_element_value(rsc, XML_LRM_ATTR_LASTOP);			/* 			if(safe_str_eq(rsc_state, "stopped")) { *//* 				continue; *//* 			} */			if(safe_str_neq(op_status, "-1")) {				crm_info("Resource state: %s %s "					 "[%s (rc=%s) after %s] on %s",					 rsc_id, rsc_state,					 op_status, last_rc, last_op, node_id);			} else {				crm_warn("Resource state: %s %s "					 "[pending %s] on %s",					 rsc_id, rsc_state, last_op, node_id);			}						);		);}
8182	/local/tlutelli/issta_data/temp/c/2005_temp/2005/8182/473b8a509095d733e97b1e794e61fd75c6a8d203/fsa.c/clean/crm/crmd/fsa.c