Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Use xbt::random instead of rand and srand
[simgrid.git] / examples / cpp / network-nonlinear / s4u-network-nonlinear.cpp
index 292503e52bb9a1a1fb2a346ea2ff5796b3138549..6384e76ddb4967da626b37137aa405fe7da608d9 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (c) 2010-2022. The SimGrid Team. All rights reserved.          */
+/* Copyright (c) 2010-2023. The SimGrid Team. All rights reserved.          */
 
 /* This program is free software; you can redistribute it and/or modify it
  * under the terms of the license (GNU LGPL) which comes with this package. */
@@ -32,7 +32,7 @@ public:
 
     /* Start dispatching all messages to receiver */
     for (int i = 0; i < messages_count; i++) {
-      std::string msg_content = std::string("Message ") + std::to_string(i);
+      std::string msg_content = "Message " + std::to_string(i);
       // Copy the data we send: the 'msg_content' variable is not a stable storage location.
       // It will be destroyed when this actor leaves the loop, ie before the receiver gets it
       auto* payload           = new std::string(msg_content);