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
Initialize allocated memory.
[simgrid.git]
/
teshsuite
/
smpi
/
auto-shared
/
auto-shared.c
diff --git
a/teshsuite/smpi/auto-shared/auto-shared.c
b/teshsuite/smpi/auto-shared/auto-shared.c
index
8966cc8
..
e8a57f1
100644
(file)
--- a/
teshsuite/smpi/auto-shared/auto-shared.c
+++ b/
teshsuite/smpi/auto-shared/auto-shared.c
@@
-33,7
+33,7
@@
int main(int argc, char *argv[])
MPI_Comm_rank(MPI_COMM_WORLD, &rank);
MPI_Comm_size(MPI_COMM_WORLD, &size);
//Let's Allocate a memory buffer
- uint64_t* buf =
malloc(
sizeof(uint64_t));
+ uint64_t* buf =
calloc(1,
sizeof(uint64_t));
//one writes data in it
if(rank==0){
*buf=size;