From 4b335d53942c847cc4c978e58697d22a3c2897ff Mon Sep 17 00:00:00 2001 From: Tom Cornebize Date: Fri, 14 Apr 2017 11:23:49 +0200 Subject: [PATCH 1/1] Call munmap with the size in smpi_shared_free. --- src/smpi/smpi_shared.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/smpi/smpi_shared.cpp b/src/smpi/smpi_shared.cpp index 04c73f637e..67159714db 100644 --- a/src/smpi/smpi_shared.cpp +++ b/src/smpi/smpi_shared.cpp @@ -427,7 +427,7 @@ void smpi_shared_free(void *ptr) xbt_free(meta->second.data); } - munmap(ptr, 0); // the POSIX says that I should not give 0 as a length, but it seems to work OK + munmap(ptr, meta->second.size); } else { XBT_DEBUG("Classic free of %p", ptr); xbt_free(ptr); -- 2.20.1