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
Make EngineImpl::tasksTemp a local variable.
[simgrid.git]
/
src
/
kernel
/
EngineImpl.cpp
diff --git
a/src/kernel/EngineImpl.cpp
b/src/kernel/EngineImpl.cpp
index fecdfb99eb03c703173b0b6f3164cbe5f70c57e5..d065c9fa2f668abc510c17c42bf2ce4921561bb4 100644
(file)
--- a/
src/kernel/EngineImpl.cpp
+++ b/
src/kernel/EngineImpl.cpp
@@
-178,11
+178,10
@@
actor::ActorImpl* EngineImpl::get_actor_by_pid(aid_t pid)
/** Execute all the tasks that are queued, e.g. `.then()` callbacks of futures. */
bool EngineImpl::execute_tasks()
{
/** Execute all the tasks that are queued, e.g. `.then()` callbacks of futures. */
bool EngineImpl::execute_tasks()
{
- xbt_assert(tasksTemp.empty());
-
if (tasks.empty())
return false;
if (tasks.empty())
return false;
+ std::vector<xbt::Task<void()>> tasksTemp;
do {
// We don't want the callbacks to modify the vector we are iterating over:
tasks.swap(tasksTemp);
do {
// We don't want the callbacks to modify the vector we are iterating over:
tasks.swap(tasksTemp);