X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/blobdiff_plain/fa9f8bd4dce9b5c37e9c66ac09c9acc2e47e5bc3..fb33f893495b18dc7a0e13182b901d4cf662150f:/src/instr/jedule/jedule_platform.cpp diff --git a/src/instr/jedule/jedule_platform.cpp b/src/instr/jedule/jedule_platform.cpp index 6aedb79adc..1590106b4e 100644 --- a/src/instr/jedule/jedule_platform.cpp +++ b/src/instr/jedule/jedule_platform.cpp @@ -59,27 +59,17 @@ void Container::addResources(std::vector hosts) } } -void Container::createHierarchy(NetZone_t from_as) +void Container::createHierarchy(sg_netzone_t from_as) { xbt_dict_cursor_t cursor = nullptr; - char *key; - NetZone_t elem; + char* key; + sg_netzone_t elem; xbt_dict_t routing_sons = from_as->children(); if (xbt_dict_is_empty(routing_sons)) { // I am no AS // add hosts to jedule platform - xbt_dynar_t table = from_as->hosts(); - unsigned int dynar_cursor; - sg_host_t host; - - std::vector hosts; - - xbt_dynar_foreach(table, dynar_cursor, host) { - hosts.push_back(host); - } - this->addResources(hosts); - xbt_dynar_free(&table); + this->addResources(*from_as->hosts()); } else { xbt_dict_foreach(routing_sons, cursor, key, elem) { jed_container_t child_container = new simgrid::jedule::Container(std::string(elem->name()));