-*/
-
-/**
- * \brief Notifies some nodes that the current node may have became their finger.
- * \param node the current node, which has just joined the system
- */
-/*
-static void notify_predecessors(node_t node)
-{
- int i, pred_id;
- int pow = 1;
- for (i = 0; i < NB_BITS; i++) {
- // find the closest node whose finger #i can be me
- pred_id = find_predecessor(node, node->id - pow + 1); // note: no "+1" in the article!
- if (pred_id != node->id) {
- remote_update_finger_table(node, pred_id, node->id, i);
- }
- pow = pow << 1; // pow = pow * 2
- }
-}
-*/
-
-/**
- * \brief Tells the current node that a node may have became its new finger.
- * \param node the current node
- * \param candidate_id id of the node that may be a new finger of the current node
- * \param finger_index index of the finger to update
- */
-/*
-static void update_finger_table(node_t node, int candidate_id, int finger_index)
-{
- int pow = 1;
- int i;
- for (i = 0; i < finger_index; i++) {
- pow = pow << 1;
- }
-
- // if (is_in_interval(candidate_id, node->id + pow, node->fingers[finger_index].id - 1)) {
- if (is_in_interval(candidate_id, node->id, node->fingers[finger_index].id - 1)) {
-// INFO3("Candidate %d is between %d and %d!", candidate_id, node->id + pow, node->fingers[finger_index].id - 1);
- // candidate_id is my new finger
- set_finger(node, finger_index, candidate_id);
- print_finger_table(node);
-
- if (node->pred_id != node->id) { // FIXME: is this necessary?
- // my predecessor may be concerned too
- remote_update_finger_table(node, node->pred_id, candidate_id, finger_index);
- }
- }
-}
-*/
-
-/**
- * \brief Tells a remote node that a node may have became its new finger.
- * \param ask_to_id id of the remote node to update
- * \param candidate_id id of the node that may be a new finger of the remote node
- * \param finger_index index of the finger to update
- */
-/*
-static void remote_update_finger_table(node_t node, int ask_to_id, int candidate_id, int finger_index)
-{
- task_data_t req_data = xbt_new0(s_task_data_t, 1);
- req_data->request_id = candidate_id;
- req_data->request_finger = finger_index;
- req_data->issuer_host_name = MSG_host_get_name(MSG_host_self());
-
- // send a "Update Finger" request to ask_to_id
- INFO3("Sending an 'Update Finger' request to %d: his finger #%d may be %d now", ask_to_id, finger_index, candidate_id);
- m_task_t task = MSG_task_create("Update Finger", 1000, 5000, req_data);
- char* mailbox = get_mailbox(ask_to_id);
- msg_comm_t comm = MSG_task_isend(task, mailbox);
- xbt_dynar_push(node->comms, &comm);
- xbt_free(mailbox);
-}
-*/