Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Add a debug message
authorthiery <thiery@48e7efb5-ca39-0410-a469-dd3cf9ba447f>
Tue, 4 Jan 2011 14:13:55 +0000 (14:13 +0000)
committerthiery <thiery@48e7efb5-ca39-0410-a469-dd3cf9ba447f>
Tue, 4 Jan 2011 14:13:55 +0000 (14:13 +0000)
git-svn-id: svn+ssh://scm.gforge.inria.fr/svn/simgrid/simgrid/trunk@9350 48e7efb5-ca39-0410-a469-dd3cf9ba447f

src/msg/task.c

index cc85717..e085aef 100644 (file)
@@ -166,8 +166,10 @@ MSG_error_t MSG_task_destroy(m_task_t task)
   xbt_assert0((task != NULL), "Invalid parameter");
 
   /* why? if somebody is using, then you can't free! ok... but will return MSG_OK? when this task will be destroyed? isn't the user code wrong? */
-  if (task->simdata->isused > 0)
+  if (task->simdata->isused > 0) {
+    DEBUG1("Cannot destroy task %p since somebody is using it", task);
     return MSG_OK;
+  }
 #ifdef HAVE_TRACING
   TRACE_msg_task_destroy(task);
 #endif