A
lgorithmique
N
umérique
D
istribuée
Public GIT Repository
projects
/
simgrid.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge branch 'master' into MC_LTL
[simgrid.git]
/
src
/
mc
/
memory_map.c
diff --git
a/src/mc/memory_map.c
b/src/mc/memory_map.c
index
ca5a15e
..
1fe0b1a
100644
(file)
--- a/
src/mc/memory_map.c
+++ b/
src/mc/memory_map.c
@@
-22,6
+22,9
@@
memory_map_t get_memory_map(void)
/* to be returned. */
fp = fopen("/proc/self/maps", "r");
/* to be returned. */
fp = fopen("/proc/self/maps", "r");
+ if(fp == NULL)
+ perror("fopen failed");
+
xbt_assert(fp,
"Cannot open /proc/self/maps to investigate the memory map of the process. Please report this bug.");
xbt_assert(fp,
"Cannot open /proc/self/maps to investigate the memory map of the process. Please report this bug.");
@@
-143,5
+146,7
@@
memory_map_t get_memory_map(void)
free(line);
free(line);
+ fclose(fp);
+
return ret;
}
return ret;
}