Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Remove constraint from LinkImpl ctor
[simgrid.git] / src / surf / network_wifi.cpp
index ccbbf0a..a39a7ca 100644 (file)
@@ -18,8 +18,9 @@ namespace resource {
  ************/
 
 NetworkWifiLink::NetworkWifiLink(const std::string& name, std::vector<double> bandwidths, lmm::System* system)
-    : LinkImpl(name, system->constraint_new(this, 1))
+    : LinkImpl(name)
 {
+  this->set_constraint(system->constraint_new(this, 1));
   for (auto bandwidth : bandwidths)
     bandwidths_.push_back({bandwidth, 1.0, nullptr});
 }