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
And 2 memleaks in simdag examples
[simgrid.git]
/
examples
/
simdag
/
daxload
/
sd_daxload.c
diff --git
a/examples/simdag/daxload/sd_daxload.c
b/examples/simdag/daxload/sd_daxload.c
index
ed2eb41
..
50391f4
100644
(file)
--- a/
examples/simdag/daxload/sd_daxload.c
+++ b/
examples/simdag/daxload/sd_daxload.c
@@
-81,7
+81,9
@@
int main(int argc, char **argv)
XBT_INFO("------------------- Run the schedule ---------------------------");
SD_simulate(-1);
XBT_INFO("------------------- Produce the trace file---------------------------");
XBT_INFO("------------------- Run the schedule ---------------------------");
SD_simulate(-1);
XBT_INFO("------------------- Produce the trace file---------------------------");
- XBT_INFO("Producing the trace of the run into %s", xbt_basename(tracefilename));
+ char * basename = xbt_basename(tracefilename);
+ XBT_INFO("Producing the trace of the run into %s", basename);
+ free(basename);
FILE *out = fopen(tracefilename, "w");
xbt_assert(out, "Cannot write to %s", tracefilename);
free(tracefilename);
FILE *out = fopen(tracefilename, "w");
xbt_assert(out, "Cannot write to %s", tracefilename);
free(tracefilename);