incarnation_data->ordered              = FALSE;
void incarnation_unpack(resource_t *rsc){	int lpc = 0;	xmlNodePtr xml_obj = rsc->xml;	xmlNodePtr xml_self = create_xml_node(NULL, XML_CIB_TAG_RESOURCE);	incarnation_variant_data_t *incarnation_data = NULL;	resource_t *self = NULL;	const char *ordered         = xmlGetProp(xml_obj, "ordered");	const char *interleave      = xmlGetProp(xml_obj, "interleave");	const char *max_incarn      = xmlGetProp(xml_obj, "max_incarnations");	const char *max_incarn_node = xmlGetProp(xml_obj, "max_per_node");	crm_verbose("Processing resource %s...", rsc->id);	crm_malloc(incarnation_data, sizeof(incarnation_variant_data_t));	incarnation_data->child_list           = NULL;	incarnation_data->interleave           = FALSE;	incarnation_data->active_incarnation   = 0;	incarnation_data->max_incarnation      = crm_atoi(max_incarn,     "1");	incarnation_data->max_incarnation_node = crm_atoi(max_incarn_node,"1");	/* this is a bit of a hack - but simplifies everything else */	copy_in_properties(xml_self, xml_obj);	if(common_unpack(xml_self, &self)) {		incarnation_data->self = self;		self->restart_type = pe_restart_restart;	} else {		crm_xml_err(xml_self, "Couldnt unpack dummy child");		return;	}	if(safe_str_eq(interleave, "true")) {		incarnation_data->interleave = TRUE;	}	if(safe_str_eq(ordered, "true")) {		incarnation_data->ordered = TRUE;	}		xml_child_iter(		xml_obj, xml_obj_child, XML_CIB_TAG_RESOURCE,		for(lpc = 0; lpc < incarnation_data->max_incarnation; lpc++) {			resource_t *child_rsc = NULL;			xmlNodePtr child_copy = copy_xml_node_recursive(xml_obj_child);			set_id(child_copy, rsc->id, lpc);						if(common_unpack(child_copy, &child_rsc)) {				incarnation_data->child_list = g_list_append(					incarnation_data->child_list, child_rsc);								crm_debug_action(					print_resource("Added", child_rsc, FALSE));			} else {				crm_err("Failed unpacking resource %s",					xmlGetProp(child_copy, XML_ATTR_ID));			}		}		/* only count the first one */		break;		);		crm_verbose("Added %d children to resource %s...",		    incarnation_data->max_incarnation, rsc->id);		rsc->variant_opaque = incarnation_data;}