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
Fix a seg fault when xbt_exit is called more than once
[simgrid.git]
/
src
/
xbt
/
xbt_main.c
diff --git
a/src/xbt/xbt_main.c
b/src/xbt/xbt_main.c
index
51708ba
..
927c613
100644
(file)
--- a/
src/xbt/xbt_main.c
+++ b/
src/xbt/xbt_main.c
@@
-42,9
+42,10
@@
xbt_init(int *argc, char **argv) {
void
xbt_exit(){
xbt_initialized--;
- if (xbt_initialized == 0)
- free(xbt_binary_name);
+ if (xbt_initialized == 0) {
+ free(xbt_binary_name);
+ xbt_fifo_exit();
+ }
xbt_log_exit();
- xbt_fifo_exit();
}