extern long int smx_total_comms;
-/**
+/*
* Finger element.
*/
typedef struct s_finger {
char mailbox[MAILBOX_NAME_SIZE]; // string representation of the id
} s_finger_t, *finger_t;
-/**
+/*
* Node data.
*/
typedef struct s_node {
TASK_PREDECESSOR_LEAVING
} e_task_type_t;
-/**
+/*
* Data attached with the tasks sent and received
*/
typedef struct s_task_data {
// a transfer has occured
- MSG_error_t status = MSG_comm_get_status(node.comm_receive);
+ msg_error_t status = MSG_comm_get_status(node.comm_receive);
if (status != MSG_OK) {
XBT_DEBUG("Failed to receive a task. Nevermind.");
// send a "Find Successor" request to ask_to_id
msg_task_t task_sent = MSG_task_create(NULL, COMP_SIZE, COMM_SIZE, req_data);
XBT_DEBUG("Sending a 'Find Successor' request (task %p) to %d for id %d", task_sent, ask_to, id);
- MSG_error_t res = MSG_task_send_with_timeout(task_sent, mailbox, timeout);
+ msg_error_t res = MSG_task_send_with_timeout(task_sent, mailbox, timeout);
if (res != MSG_OK) {
XBT_DEBUG("Failed to send the 'Find Successor' request (task %p) to %d for id %d",
// send a "Get Predecessor" request to ask_to_id
XBT_DEBUG("Sending a 'Get Predecessor' request to %d", ask_to);
msg_task_t task_sent = MSG_task_create(NULL, COMP_SIZE, COMM_SIZE, req_data);
- MSG_error_t res = MSG_task_send_with_timeout(task_sent, mailbox, timeout);
+ msg_error_t res = MSG_task_send_with_timeout(task_sent, mailbox, timeout);
if (res != MSG_OK) {
XBT_DEBUG("Failed to send the 'Get Predecessor' request (task %p) to %d",
MSG_function_register("node", node);
MSG_launch_application(application_file);
- MSG_error_t res = MSG_main();
+ msg_error_t res = MSG_main();
XBT_CRITICAL("Messages created: %ld", smx_total_comms);
XBT_INFO("Simulated time: %g", MSG_get_clock());