X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/blobdiff_plain/35e66f1b2c4ea53b8d44b527e27cdd10e16b3d55..da82494b57755f7709200dec34441cad787ddde2:/src/surf/network_ns3.cpp diff --git a/src/surf/network_ns3.cpp b/src/surf/network_ns3.cpp index 7868a63259..f51fd2568c 100644 --- a/src/surf/network_ns3.cpp +++ b/src/surf/network_ns3.cpp @@ -185,6 +185,9 @@ static void clusterCreation_cb(simgrid::kernel::routing::ClusterCreationArgs con { ns3::NodeContainer Nodes; + xbt_assert(cluster.topology == simgrid::kernel::routing::ClusterTopology::FLAT, + "NS-3 is supported only by flat clusters. Do not use with other topologies"); + for (int const& i : cluster.radicals) { // Create private link std::string host_id = cluster.prefix + std::to_string(i) + cluster.suffix; @@ -229,6 +232,7 @@ static void routeCreation_cb(bool symmetrical, simgrid::kernel::routing::NetPoin simgrid::kernel::routing::NetPoint* /*gw_dst*/, std::vector const& link_list) { + xbt_assert(src && dst, "NS-3: add_route, invalid src or destination"); if (link_list.size() == 1) { auto const* link = static_cast(link_list[0]);