/* This program is free software; you can redistribute it and/or modify it
* under the terms of the license (GNU LGPL) which comes with this package. */
-#include "src/sthread/sthread.h" // sthread_inside_simgrid
#include "src/xbt/log_private.hpp"
#include "xbt/string.hpp"
#include "xbt/sysdep.h"
if (category->initialized)
return priority >= category->threshold;
- int old_inside_simgrid = sthread_inside_simgrid;
- sthread_inside_simgrid = 1;
if (log_cat_init_mutex != nullptr)
log_cat_init_mutex->lock();
category->initialized = 1;
if (log_cat_init_mutex != nullptr)
log_cat_init_mutex->unlock();
- sthread_inside_simgrid = old_inside_simgrid;
return priority >= category->threshold;
}
throw std::invalid_argument(simgrid::xbt::string_printf("Unknown appender log type: '%s'", value));
}
} else if (strncmp(option, "fmt", option_len) == 0) {
- set.fmt = std::string(value);
+ set.fmt = value;
} else {
xbt_die("Unknown setting of the log category: '%.*s'", static_cast<int>(option_len), option);
}