]> AND Public Git Repository - simgrid.git/blobdiff - src/mc/inspect/mc_unw_vmread.cpp
Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Allow ns3 to be idempotent if correctly patched
[simgrid.git] / src / mc / inspect / mc_unw_vmread.cpp
index 671fccd1ddd05de7717e7fca93aa40d5cdf37ad9..21fc4789ae1f2f6003c98ac000a698ca4130a459 100644 (file)
@@ -1,12 +1,12 @@
 /** \file  Libunwind namespace implementation using process_vm_readv.       */
 
-/* Copyright (c) 2015-2022. The SimGrid Team. All rights reserved.          */
+/* Copyright (c) 2015-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. */
 
 #include "src/mc/inspect/mc_unw.hpp"
-#include "src/mc/remote/RemoteProcess.hpp"
+#include "src/mc/sosp/RemoteProcessMemory.hpp"
 
 #include <sys/types.h>
 #include <sys/uio.h>
@@ -57,7 +57,7 @@ static int access_mem(const unw_addr_space_t as, const unw_word_t addr, unw_word
   // On older kernels, it is necessary to ptrace the target process.
   size_t count = size;
   auto off     = static_cast<off_t>(addr);
-  auto* buf    = reinterpret_cast<char*>(valp);
+  auto* buf    = reinterpret_cast<std::byte*>(valp);
   int fd       = simgrid::mc::open_vm(pid, O_RDONLY);
   if (fd < 0)
     return -UNW_EINVAL;