]> AND Private Git Repository - loba.git/blob - neighbor.cpp
Logo AND Algorithmique Numérique Distribuée

Private GIT Repository
e7a4666151df22ecc771ef1c9c883cfdb8e4f0ec
[loba.git] / neighbor.cpp
1 #include <xbt/sysdep.h>
2 #include "neighbor.h"
3
4 neighbor::neighbor(const char* hostname)
5 {
6     load = std::numeric_limits<double>::infinity();
7     debt = 0.0;
8     name = xbt_strdup(hostname);
9     ctrl_mbox = bprintf("%s_ctrl", hostname);
10     data_mbox = bprintf("%s_data", hostname);
11 }
12
13 neighbor::~neighbor()
14 {
15     free(data_mbox);
16     free(ctrl_mbox);
17     free(name);
18 }