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
Evaluating the expression of xbt_assert must not have side effects.
[simgrid.git]
/
src
/
xbt
/
log.c
diff --git
a/src/xbt/log.c
b/src/xbt/log.c
index
d00f860
..
b4e3010
100644
(file)
--- a/
src/xbt/log.c
+++ b/
src/xbt/log.c
@@
-1060,13
+1060,11
@@
void xbt_log_layout_set(xbt_log_category_t cat, xbt_log_layout_t lay)
cat->name);
xbt_log_appender_set(cat, xbt_log_appender_file_new(NULL));
}
cat->name);
xbt_log_appender_set(cat, xbt_log_appender_file_new(NULL));
}
- if (cat->layout && cat != &_XBT_LOGV(root)) {
- /* better leak the default layout than check every categories to
- change it */
+ if (cat->layout) {
if (cat->layout->free_) {
cat->layout->free_(cat->layout);
if (cat->layout->free_) {
cat->layout->free_(cat->layout);
- free(cat->layout);
}
}
+ free(cat->layout);
}
cat->layout = lay;
xbt_log_additivity_set(cat, 0);
}
cat->layout = lay;
xbt_log_additivity_set(cat, 0);