Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Pointer to const++ (sonar).
authorArnaud Giersch <arnaud.giersch@univ-fcomte.fr>
Thu, 8 Dec 2022 09:49:32 +0000 (10:49 +0100)
committerArnaud Giersch <arnaud.giersch@univ-fcomte.fr>
Thu, 8 Dec 2022 09:49:32 +0000 (10:49 +0100)
[ci-skip]

teshsuite/s4u/io-stream/io-stream.cpp

index 7734156..4b19f77 100644 (file)
@@ -12,9 +12,9 @@ XBT_LOG_NEW_DEFAULT_CATEGORY(io_stream, "Messages specific for this simulation")
 static void streamer(size_t size)
 {
   auto* bob        = sg4::Host::by_name("bob");
-  auto* bob_disk   = bob->get_disks().front();
   auto* alice      = sg4::Host::by_name("alice");
-  auto* alice_disk = alice->get_disks().front();
+  const auto* bob_disk   = bob->get_disks().front();
+  const auto* alice_disk = alice->get_disks().front();
   double clock = sg4::Engine::get_clock();
 
   XBT_INFO("[Bob -> Alice] Store and Forward (1 block)");