Firstly the PATH and MESSID from the message are set for SUBPAR (SUBPAR_PUTPATH()) in case it wants to reply with a message or request a parameter value as a result of this message, then a DTASK routine appropriate to the CONTEXT is called.
When the required action for the CONTEXT is complete, the transaction is ended by calling (DTASK_COMSHUT()) which flushes any error messages on the stack to the master task (using ERR_CLEAR()) before sending a final acknowledgment. (The master task must therefore be prepared to handle any MESSYS__INFORM messages prior to the final acknowledgement in any CONTEXT.) The final acknowledgement will have an appropriate message status and the message value will depend upon the status and the CONTEXT.
ADAM The Control Subsystem