action->timeout = atoi(value);
action->timeout = crm_parse_int(value, NULL);
unpack_action(crm_data_t *xml_action) {	action_t   *action = NULL;	crm_data_t *action_copy = NULL;	const char *value = crm_element_value(xml_action, XML_ATTR_ID);	if(value == NULL) {		crm_err("Actions must have an id!");		crm_log_xml_debug_3(xml_action, "Action with missing id");		return NULL;	}		action_copy = copy_xml(xml_action);	crm_malloc0(action, sizeof(action_t));	if(action == NULL) {		return NULL;	}		action->id       = atoi(value);	action->timeout  = 0;	action->interval = 0;	action->timer    = NULL;	action->invoked  = FALSE;	action->sent_update = FALSE;	action->complete = FALSE;	action->can_fail = FALSE;	action->type     = action_type_rsc;	action->xml      = action_copy;		if(safe_str_eq(crm_element_name(action_copy), XML_GRAPH_TAG_RSC_OP)) {		action->type = action_type_rsc;	} else if(safe_str_eq(crm_element_name(action_copy),			      XML_GRAPH_TAG_PSEUDO_EVENT)) {		action->type = action_type_pseudo;	} else if(safe_str_eq(crm_element_name(action_copy),			      XML_GRAPH_TAG_CRM_EVENT)) {		action->type = action_type_crm;	}	action->params = xml2list(action_copy);	value = g_hash_table_lookup(action->params, "timeout");	if(value != NULL) {		action->timeout = atoi(value);	}	value = g_hash_table_lookup(action->params, "interval");	if(value != NULL) {		action->interval = atoi(value);	}	value = g_hash_table_lookup(action->params, "can_fail");	if(value != NULL) {			cl_str_to_boolean(value, &(action->can_fail));	}		crm_debug_3("Action %d has timer set to %dms",		  action->id, action->timeout);		crm_malloc0(action->timer, sizeof(te_timer_t));	action->timer->timeout   = 2 * action->timeout;	action->timer->source_id = -1;	action->timer->reason    = timeout_action;	action->timer->action    = action;	return action;}