Lindy,
The child doesn't need to know anything about that ECB.  The ECB
specified on the ATTACH macro is used by the system.  When the subtask
completes and returns to the system (via the oldest PRB on the task
queue issuing an SVC 3), the system will post the ECB to notify the
mother task that it is safe to issue the DETACH.  If the child task
POSTS the ECB, and continues to execute, when the mother wakes up and
issues the DETACH you will see x3E abends caused by terminating a TCB
that was still running.

Wayne Driscoll
Product Developer
JME Software LLC
NOTE:  All opinions are strictly my own.



-----Original Message-----
From: IBM Mainframe Discussion List [mailto:[EMAIL PROTECTED] On
Behalf Of Lindy Mayfield
Sent: Friday, January 18, 2008 5:32 PM
To: IBM-MAIN@BAMA.UA.EDU
Subject: How does ATTACH pass address of ECB to child?

I wonder if I am missing something.

Here is what I think:  My main program does an 

ATTACH,EP=CHILD,ECB=ECB1
WAIT ECB=ECB1
DETACH (R1)

The program CHILD does its thing and then when done

POST ECB1

Which IIUC causes the main program to stop waiting. How does CHILD know
the address of ECB1 in order to POST?  Or do I need to pass the address
as a parameter?

Lindy

----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [EMAIL PROTECTED] with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html

Reply via email to