X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/blobdiff_plain/84ed556b8c7cf58207b813f2104075767c837d36..06aaaaffb5ec865a880e32dcff6768792ce78446:/src/msg/task.c diff --git a/src/msg/task.c b/src/msg/task.c index 067793cb7f..8aae84d883 100644 --- a/src/msg/task.c +++ b/src/msg/task.c @@ -76,6 +76,11 @@ m_task_t MSG_task_create(const char *name, double compute_duration, return task; } +/** prevent the task from being destroyed too quickly (but also prevent it from being sent). Mainly useful in bindings */ +void MSG_task_ref(m_task_t t) { + t->simdata->refcount++; +} + /** \ingroup m_task_management * \brief Return the user data of a #m_task_t. *