X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/blobdiff_plain/b9625f82f86db0674e911887addce45dca31b57f..813e836067a1aa922c5fb1432300b7e6390ee352:/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 f633892ff3..d676ff5cef 100644 --- a/teshsuite/s4u/storage_client_server/storage_client_server.cpp +++ b/teshsuite/s4u/storage_client_server/storage_client_server.cpp @@ -51,8 +51,8 @@ static void hsm_put(const std::string& remote_host, const std::string& src, cons // Send file XBT_INFO("%s sends %llu to %s", simgrid::s4u::this_actor::get_cname(), read_size, remote_host.c_str()); - std::string* payload = new std::string(simgrid::xbt::string_printf("%s %llu", dest.c_str(), read_size)); - simgrid::s4u::Mailbox* mailbox = simgrid::s4u::Mailbox::by_name(remote_host); + auto* payload = new std::string(simgrid::xbt::string_printf("%s %llu", dest.c_str(), read_size)); + auto* mailbox = simgrid::s4u::Mailbox::by_name(remote_host); mailbox->put(payload, read_size); simgrid::s4u::this_actor::sleep_for(.4); } @@ -61,7 +61,7 @@ static void display_disk_content(const simgrid::s4u::Disk* disk) { XBT_INFO("*** Dump a disk ***"); XBT_INFO("Print the content of the disk: %s", disk->get_cname()); - const std::map* content = disk->extension()->get_content(); + const auto* content = disk->extension()->get_content(); if (not content->empty()) { for (auto const& entry : *content) XBT_INFO(" %s size: %llu bytes", entry.first.c_str(), entry.second); @@ -127,7 +127,7 @@ static void server() XBT_INFO("Server waiting for transfers ..."); while (true) { - const std::string* msg = static_cast(mailbox->get()); + const std::string* msg = mailbox->get(); if (*msg == "finalize") { // Shutdown ... delete msg; break;