const char *id = xmlGetProp(xml_obj, XML_ATTR_ID);
const char *id       = xmlGetProp(xml_obj, XML_ATTR_ID); const char *stopfail = xmlGetProp(xml_obj, "on_stopfail"); const char *restart  = xmlGetProp(xml_obj, "restart_type"); const char *timeout  = xmlGetProp(xml_obj, "timeout"); const char *priority = xmlGetProp(xml_obj, XML_CIB_ATTR_PRIORITY);
common_unpack(xmlNodePtr xml_obj, resource_t **rsc){	const char *id = xmlGetProp(xml_obj, XML_ATTR_ID);		crm_verbose("Processing resource...");		if(id == NULL) {		crm_err("Must specify id tag in <resource>");		return FALSE;			} else if(rsc == NULL) {		crm_err("Nowhere to unpack resource into");		return FALSE;			}	crm_malloc(*rsc, sizeof(resource_t));		if(*rsc == NULL) {		return FALSE;	}		(*rsc)->id  = id;	(*rsc)->xml = xml_obj;	(*rsc)->variant = get_resource_type(xml_obj->name);		if((*rsc)->variant == pe_unknown) {		crm_err("Unknown resource type: %s", xml_obj->name);		crm_free(*rsc);		return FALSE;	}		(*rsc)->fns = &resource_class_functions[(*rsc)->variant];	(*rsc)->fns->unpack(*rsc);	return TRUE;}