X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/blobdiff_plain/230573edfbee19213bd2a83d178ffb69283f4e07..74c1bf2b26c5a3aa0d8c29674dc12993e7c0de15:/teshsuite/s4u/storage_client_server/storage_client_server.cpp diff --git a/teshsuite/s4u/storage_client_server/storage_client_server.cpp b/teshsuite/s4u/storage_client_server/storage_client_server.cpp index 4e443200ce..df64ea9a32 100644 --- a/teshsuite/s4u/storage_client_server/storage_client_server.cpp +++ b/teshsuite/s4u/storage_client_server/storage_client_server.cpp @@ -14,7 +14,7 @@ static void display_storage_properties(simgrid::s4u::Storage* storage) if (not props->empty()) { XBT_INFO("\tProperties of mounted storage: %s", storage->getName()); - for (auto elm : *props) { + for (auto const& elm : *props) { XBT_INFO(" %s->%s", elm.first.c_str(), elm.second.c_str()); } } else { @@ -63,7 +63,7 @@ static void display_storage_content(simgrid::s4u::Storage* storage) XBT_INFO("Print the content of the storage element: %s", storage->getName()); std::map* content = storage->getContent(); if (not content->empty()) { - for (auto entry : *content) + for (auto const& entry : *content) XBT_INFO("\t%s size: %llu bytes", entry.first.c_str(), entry.second); } else { XBT_INFO("\tNo content."); @@ -94,7 +94,7 @@ static void dump_platform_storages() { std::map* storages = simgrid::s4u::allStorages(); - for (auto storage : *storages) { + for (auto const& storage : *storages) { XBT_INFO("Storage %s is attached to %s", storage.first.c_str(), storage.second->getHost()->getCname()); storage.second->setProperty("other usage", "gpfs"); } @@ -105,7 +105,7 @@ static void storage_info(simgrid::s4u::Host* host) { XBT_INFO("*** Storage info on %s ***", host->getCname()); - for (auto elm : host->getMountedStorages()) { + for (auto const& elm : host->getMountedStorages()) { const char* mount_name = elm.first.c_str(); simgrid::s4u::Storage* storage = elm.second; XBT_INFO("\tStorage name: %s, mount name: %s", storage->getName(), mount_name);