Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
MSG_process_ref/unref: allow to fiddle with the process refcounting
authorMartin Quinson <martin.quinson@loria.fr>
Mon, 13 Mar 2017 00:22:21 +0000 (01:22 +0100)
committerMartin Quinson <martin.quinson@loria.fr>
Mon, 13 Mar 2017 00:25:25 +0000 (01:25 +0100)
commit32965191d7fcfb85c4f0da9f118826b70f7d32ba
treeac1aa20879f551fcc71c23a70300002ba64b5f4e
parent01fdeeeaa47199383ca69d244df546b45f8b954c
MSG_process_ref/unref: allow to fiddle with the process refcounting

This is useful to avoid that a process gets deleted before we're done
with it. This is what happened in the process-join example, where we
were joining the process after its end. So we have to increase its
refcount while it's still alive to make sure that it does not get
destroyed too early.

This would be automated in C++ with RAII but we are not there yet.
ChangeLog
examples/msg/process-join/process-join.c
examples/msg/process-join/process-join.tesh
include/simgrid/msg.h
src/msg/msg_process.cpp